To achieve this, the "on-fail" connection parameter has been added
to control the action performed on connection loss.
The supported values are "stop-retry-exit", "serve-retry-exit" and
- "server-retry-continue". They indicate if the server should disable
+ "serve-retry-continue". They indicate if the server should disable
the service on connection loss ("stop-retry-exit") or if on recovery
failure the server should shut down ("stop-retry-exit" and
- "serve-retry-exit") or continue ("server-retry-continue").
+ "serve-retry-exit") or continue ("serve-retry-continue").
The default value used (if not configured) is "stop-retry-exit" for
lease, host and config backends, and "serve-retry-continue" for
forensic log.
The ``on-fail`` parameter configures the actions the server should take when a
connection is lost. It can have one of the following values:
-``stop-retry-exit`` which indicates that the server should stop the service
-while it tries to recover the connection and exit if recovery is not successful
-after ``max-reconnect-tries``.
-``serve-retry-exit`` which indicates that the server should not stop the service
-while it tries to recover the connection and exit if recovery is not successful
-after ``max-reconnect-tries``.
-``serve-retry-continue`` which indicates that the server should not stop the
-service while it tries to recover the connection and not exit if recovery is not
-successful after ``max-reconnect-tries``.
+
+- ``stop-retry-exit`` which indicates that the server should stop the service
+ while it tries to recover the connection and exit if recovery is not
+ successful after ``max-reconnect-tries``.
+
+- ``serve-retry-exit`` which indicates that the server should not stop the
+ service while it tries to recover the connection and exit if recovery is not
+ successful after ``max-reconnect-tries``.
+
+- ``serve-retry-continue`` which indicates that the server should not stop the
+ service while it tries to recover the connection and not exit if recovery is
+ not successful after ``max-reconnect-tries``.
If connectivity to all backends is restored, the server returns to normal
operations. If the connection can not be restored and the server is configured
"Dhcp4": { "lease-database": { "on-fail" : "stop-retry-exit", ... }, ... }
-The default value for MySQL and PostgreSQL is ``stop-retry-exit``, which
-disables the dhcp service while trying to automatically recover lost connections
-and shuts down the server on failure after ``max-reconnect-tries``.
-Other valid values are: ``serve-retry-exit`` which does not disable the dhcp
-service but shuts down the server on failure after ``max-reconnect-tries`` and
-``serve-retry-continue`` which does not disable the dhcp service and does not
-shut down the server even if the recovery fails.
+The possible values are:
+
+- ``stop-retry-exit`` disables the DHCP service while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``. This is the default value for MySQL and PostgreSQL.
+
+- ``serve-retry-exit`` DHCP service continues while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``.
+
+- ``serve-retry-continue`` DHCP service continues and does not shut down the
+ server even if the recovery fails.
.. note::
"Dhcp4": { "hosts-database": { "on-fail" : "stop-retry-exit", ... }, ... }
-The default value for MySQL and PostgreSQL is ``stop-retry-exit``, which
-disables the dhcp service while trying to automatically recover lost connections
-and shuts down the server on failure after ``max-reconnect-tries``.
-Other valid values are: ``serve-retry-exit`` which does not disable the dhcp
-service but shuts down the server on failure after ``max-reconnect-tries`` and
-``serve-retry-continue`` which does not disable the dhcp service and does not
-shut down the server even if the recovery fails.
+The possible values are:
+
+- ``stop-retry-exit`` disables the DHCP service while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``. This is the default value for MySQL and PostgreSQL.
+
+- ``serve-retry-exit`` DHCP service continues while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``.
+
+- ``serve-retry-continue`` DHCP service continues and does not shut down the
+ server even if the recovery fails.
.. note::
"Dhcp6": { "lease-database": { "on-fail" : "stop-retry-exit", ... }, ... }
-The default value for MySQL and PostgreSQL is ``stop-retry-exit``, which
-disables the dhcp service while trying to automatically recover lost connections
-and shuts down the server on failure after ``max-reconnect-tries``.
-Other valid values are: ``serve-retry-exit`` which does not disable the dhcp
-service but shuts down the server on failure after ``max-reconnect-tries`` and
-``serve-retry-continue`` which does not disable the dhcp service and does not
-shut down the server even if the recovery fails.
+The possible values are:
+
+- ``stop-retry-exit`` disables the DHCP service while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``. This is the default value for MySQL and PostgreSQL.
+
+- ``serve-retry-exit`` DHCP service continues while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``.
+
+- ``serve-retry-continue`` DHCP service continues and does not shut down the
+ server even if the recovery fails.
.. note::
"Dhcp6": { "hosts-database": { "on-fail" : "stop-retry-exit", ... }, ... }
-The default value for MySQL and PostgreSQL is ``stop-retry-exit``, which
-disables the dhcp service while trying to automatically recover lost connections
-and shuts down the server on failure after ``max-reconnect-tries``.
-Other valid values are: ``serve-retry-exit`` which does not disable the dhcp
-service but shuts down the server on failure after ``max-reconnect-tries`` and
-``serve-retry-continue`` which does not disable the dhcp service and does not
-shut down the server even if the recovery fails.
+The possible values are:
+
+- ``stop-retry-exit`` disables the DHCP service while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``. This is the default value for MySQL and PostgreSQL.
+
+- ``serve-retry-exit`` DHCP service continues while trying to automatically
+ recover lost connections. Shuts down the server on failure after exhausting
+ ``max-reconnect-tries``.
+
+- ``serve-retry-continue`` DHCP service continues and does not shut down the
+ server even if the recovery fails.
.. note::
case OnFailAction::STOP_RETRY_EXIT:
return ("stop-retry-exit");
case OnFailAction::SERVE_RETRY_EXIT:
- return ("server-retry-exit");
+ return ("serve-retry-exit");
case OnFailAction::SERVE_RETRY_CONTINUE:
return ("serve-retry-continue");
}
return (OnFailAction::STOP_RETRY_EXIT);
} else if (text == "serve-retry-exit") {
return (OnFailAction::SERVE_RETRY_EXIT);
- } else if (text == "server-retry-continue") {
+ } else if (text == "serve-retry-continue") {
return (OnFailAction::SERVE_RETRY_CONTINUE);
} else {
isc_throw(BadValue, "Invalid action on connection loss: " << text);