refactored the session state
monitoring the reachability of the host
refactoring of the parameters initialisation and added an option to disable the tracking of the session duration