From: Marcin Siodelski Date: Tue, 4 Dec 2018 16:03:46 +0000 (+0100) Subject: [#173,!154] reconnect-wait-time is now in milliseconds. X-Git-Tag: 339-doxygen-errors_base~10^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=782fdf35367e052eb505d0fe531ab183ff768f52;p=thirdparty%2Fkea.git [#173,!154] reconnect-wait-time is now in milliseconds. --- diff --git a/doc/guide/dhcp4-srv.xml b/doc/guide/dhcp4-srv.xml index 709c35e1fb..ab94e0d7f0 100644 --- a/doc/guide/dhcp4-srv.xml +++ b/doc/guide/dhcp4-srv.xml @@ -496,13 +496,14 @@ recovery and the server will exit immediately upon detecting a loss of connectiv (MySQL and Postgres only). -The number of seconds the server will wait in between attempts to reconnect to the +The number of milliseconds the server will wait in between attempts to reconnect to the lease database after connectivity has been lost may also be specified: -"Dhcp4": { "lease-database": { "reconnect-wait-time" : number-of-seconds, ... }, ... } +"Dhcp4": { "lease-database": { "reconnect-wait-time" : number-of-milliseconds, ... }, ... } -A value of zero (the default) disables automatic recovery and the server will exit -immediately upon detecting a loss of connectivity (MySQL and Postgres only). +The default value for MySQL and Postgres is 0, which disables automatic recovery and +causes the server to exit immediately upon detecting the loss of connectivity. +The default value for Cassandra is 2000 ms. Finally, the credentials of the account under which the server will access the database should be set: @@ -662,13 +663,14 @@ recovery and the server will exit immediately upon detecting a loss of connectiv (MySQL and Postgres only). -The number of seconds the server will wait in between attempts to reconnect to the +The number of milliseconds the server will wait in between attempts to reconnect to the host database after connectivity has been lost may also be specified: -"Dhcp4": { "hosts-database": { "reconnect-wait-time" : number-of-seconds, ... }, ... } +"Dhcp4": { "hosts-database": { "reconnect-wait-time" : number-of-milliseconds, ... }, ... } -A value of zero (the default) disables automatic recovery and the server will exit -immediately upon detecting a loss of connectivity (MySQL and Postgres only). +The default value for MySQL and Postgres is 0, which disables automatic recovery and +causes the server to exit immediately upon detecting the loss of connectivity. +The default value for Cassandra is 2000 ms. diff --git a/doc/guide/dhcp6-srv.xml b/doc/guide/dhcp6-srv.xml index 230fbfe3e5..78f7ac82ad 100644 --- a/doc/guide/dhcp6-srv.xml +++ b/doc/guide/dhcp6-srv.xml @@ -493,13 +493,14 @@ recovery and the server will exit immediately upon detecting a loss of connectiv (MySQL and Postgres only). -The number of seconds the server will wait in between attempts to reconnect to the +The number of milliseconds the server will wait in between attempts to reconnect to the lease database after connectivity has been lost may also be specified: -"Dhcp6": { "lease-database": { "reconnect-wait-time" : number-of-seconds, ... }, ... } +"Dhcp6": { "lease-database": { "reconnect-wait-time" : number-of-milliseconds, ... }, ... } -A value of zero (the default) disables automatic recovery and the server will exit -immediately upon detecting a loss of connectivity (MySQL and Postgres only). +The default value for MySQL and Postgres is 0, which disables automatic recovery and +causes the server to exit immediately upon detecting the loss of connectivity. +The default value for Cassandra is 2000 ms. Note that host parameter is used by MySQL and PostgreSQL @@ -599,13 +600,14 @@ recovery and the server will exit immediately upon detecting a loss of connectiv (MySQL and Postgres only). -The number of seconds the server will wait in between attempts to reconnect to the +The number of milliseconds the server will wait in between attempts to reconnect to the host database after connectivity has been lost may also be specified: -"Dhcp6": { "hosts-database": { "reconnect-wait-time" : number-of-seconds, ... }, ... } +"Dhcp6": { "hosts-database": { "reconnect-wait-time" : number-of-milliseconds, ... }, ... } -A value of zero (the default) disables automatic recovery and the server will exit -immediately upon detecting a loss of connectivity (MySQL and Postgres only). +The default value for MySQL and Postgres is 0, which disables automatic recovery and +causes the server to exit immediately upon detecting the loss of connectivity. +The default value for Cassandra is 2000 ms. Finally, the credentials of the account under which the server will access the database should be set: diff --git a/src/bin/dhcp4/ctrl_dhcp4_srv.cc b/src/bin/dhcp4/ctrl_dhcp4_srv.cc index 06e1c3927d..766e1026eb 100644 --- a/src/bin/dhcp4/ctrl_dhcp4_srv.cc +++ b/src/bin/dhcp4/ctrl_dhcp4_srv.cc @@ -904,7 +904,7 @@ ControlledDhcpv4Srv::dbReconnect(ReconnectCtlPtr db_reconnect_ctl) { TimerMgr::instance()->registerTimer("Dhcp4DbReconnectTimer", boost::bind(&ControlledDhcpv4Srv::dbReconnect, this, db_reconnect_ctl), - db_reconnect_ctl->retryInterval() * 1000, + db_reconnect_ctl->retryInterval(), asiolink::IntervalTimer::ONE_SHOT); } diff --git a/src/bin/dhcp4/dhcp4_messages.mes b/src/bin/dhcp4/dhcp4_messages.mes index 7b6d455e0f..f0d486a6c3 100644 --- a/src/bin/dhcp4/dhcp4_messages.mes +++ b/src/bin/dhcp4/dhcp4_messages.mes @@ -158,7 +158,7 @@ An error message indicating that an attempt to reconnect to the lease and/or host data bases has failed. This occurs after connectivity to either one has been lost and an automatic attempt to reconnect has failed. -% DHCP4_DB_RECONNECT_ATTEMPT_SCHEDULE scheduling attempt %1 of %2 in %3 seconds +% DHCP4_DB_RECONNECT_ATTEMPT_SCHEDULE scheduling attempt %1 of %2 in %3 milliseconds An informational message indicating that the server is scheduling the next attempt to reconnect to its lease and/or host databases. This occurs when the server has lost databse connectivity and is attempting to reconnect diff --git a/src/bin/dhcp6/ctrl_dhcp6_srv.cc b/src/bin/dhcp6/ctrl_dhcp6_srv.cc index 989840089f..b45ba517c0 100644 --- a/src/bin/dhcp6/ctrl_dhcp6_srv.cc +++ b/src/bin/dhcp6/ctrl_dhcp6_srv.cc @@ -924,7 +924,7 @@ ControlledDhcpv6Srv::dbReconnect(ReconnectCtlPtr db_reconnect_ctl) { TimerMgr::instance()->registerTimer("Dhcp6DbReconnectTimer", boost::bind(&ControlledDhcpv6Srv::dbReconnect, this, db_reconnect_ctl), - db_reconnect_ctl->retryInterval() * 1000, + db_reconnect_ctl->retryInterval(), asiolink::IntervalTimer::ONE_SHOT); } diff --git a/src/bin/dhcp6/dhcp6_messages.mes b/src/bin/dhcp6/dhcp6_messages.mes index c7e3aab83e..4cdcc57f35 100644 --- a/src/bin/dhcp6/dhcp6_messages.mes +++ b/src/bin/dhcp6/dhcp6_messages.mes @@ -118,7 +118,7 @@ An error message indicating that an attempt to reconnect to the lease and/or host data bases has failed. This occurs after connectivity to either one has been lost and an automatic attempt to reconnect has failed. -% DHCP6_DB_RECONNECT_ATTEMPT_SCHEDULE scheduling attempt %1 of %2 in %3 seconds +% DHCP6_DB_RECONNECT_ATTEMPT_SCHEDULE scheduling attempt %1 of %2 in %3 milliseconds An informational message indicating that the server is scheduling the next attempt to reconnect to its lease and/or host databases. This occurs when the server has lost databse connectivity and is attempting to reconnect