extern const isc::log::MessageID CTRL_AGENT_CONFIG_FAIL = "CTRL_AGENT_CONFIG_FAIL";
extern const isc::log::MessageID CTRL_AGENT_CONFIG_SYNTAX_WARNING = "CTRL_AGENT_CONFIG_SYNTAX_WARNING";
extern const isc::log::MessageID CTRL_AGENT_FAILED = "CTRL_AGENT_FAILED";
+extern const isc::log::MessageID CTRL_AGENT_HTTPS_SERVICE_REUSED = "CTRL_AGENT_HTTPS_SERVICE_REUSED";
extern const isc::log::MessageID CTRL_AGENT_HTTPS_SERVICE_STARTED = "CTRL_AGENT_HTTPS_SERVICE_STARTED";
+extern const isc::log::MessageID CTRL_AGENT_HTTP_SERVICE_REUSED = "CTRL_AGENT_HTTP_SERVICE_REUSED";
extern const isc::log::MessageID CTRL_AGENT_HTTP_SERVICE_STARTED = "CTRL_AGENT_HTTP_SERVICE_STARTED";
extern const isc::log::MessageID CTRL_AGENT_RUN_EXIT = "CTRL_AGENT_RUN_EXIT";
extern const isc::log::MessageID CTRL_AGENT_STARTED = "CTRL_AGENT_STARTED";
"CTRL_AGENT_CONFIG_FAIL", "Control Agent configuration failed: %1",
"CTRL_AGENT_CONFIG_SYNTAX_WARNING", "Control Agent configuration syntax warning: %1",
"CTRL_AGENT_FAILED", "application experienced a fatal error: %1",
+ "CTRL_AGENT_HTTPS_SERVICE_REUSED", "reused HTTPS service bound to address %1:%2",
"CTRL_AGENT_HTTPS_SERVICE_STARTED", "HTTPS service bound to address %1:%2",
+ "CTRL_AGENT_HTTP_SERVICE_REUSED", "reused HTTP service bound to address %1:%2",
"CTRL_AGENT_HTTP_SERVICE_STARTED", "HTTP service bound to address %1:%2",
"CTRL_AGENT_RUN_EXIT", "application is exiting the event loop",
"CTRL_AGENT_STARTED", "Kea Control Agent version %1 started",
extern const isc::log::MessageID CTRL_AGENT_CONFIG_FAIL;
extern const isc::log::MessageID CTRL_AGENT_CONFIG_SYNTAX_WARNING;
extern const isc::log::MessageID CTRL_AGENT_FAILED;
+extern const isc::log::MessageID CTRL_AGENT_HTTPS_SERVICE_REUSED;
extern const isc::log::MessageID CTRL_AGENT_HTTPS_SERVICE_STARTED;
+extern const isc::log::MessageID CTRL_AGENT_HTTP_SERVICE_REUSED;
extern const isc::log::MessageID CTRL_AGENT_HTTP_SERVICE_STARTED;
extern const isc::log::MessageID CTRL_AGENT_RUN_EXIT;
extern const isc::log::MessageID CTRL_AGENT_STARTED;
This is a fatal error message issued when the Control Agent application
encounters an unrecoverable error from within the event loop.
+% CTRL_AGENT_HTTPS_SERVICE_REUSED reused HTTPS service bound to address %1:%2
+This informational message indicates that the server has reused existing
+HTTPS service on the specified address and port. Note that any change in
+the TLS setup was ignored.
+
% CTRL_AGENT_HTTPS_SERVICE_STARTED HTTPS service bound to address %1:%2
This informational message indicates that the server has started HTTPS service
on the specified address and port. All control commands should be sent to this
address and port over a TLS channel.
+% CTRL_AGENT_HTTP_SERVICE_REUSED reused HTTP service bound to address %1:%2
+This informational message indicates that the server has reused existing
+HTTPS service on the specified address and port.
+
% CTRL_AGENT_HTTP_SERVICE_STARTED HTTP service bound to address %1:%2
This informational message indicates that the server has started HTTP service
on the specified address and port. All control commands should be sent to this
// active listeners. The next step will be to remove all other
// active listeners, but we do it inside the main process loop.
http_listeners_.push_back(http_listener);
+ } else if (!http_listeners_.empty()) {
+ // Reconfig keeping the same address and port.
+ if (http_listeners_.back()->getTlsContext()) {
+ LOG_INFO(agent_logger, CTRL_AGENT_HTTPS_SERVICE_REUSED)
+ .arg(server_address.toText())
+ .arg(server_port);
+ } else {
+ LOG_INFO(agent_logger, CTRL_AGENT_HTTP_SERVICE_REUSED)
+ .arg(server_address.toText())
+ .arg(server_port);
+ }
+ return;
}
// Ok, seems we're good to go.
if (use_https) {
LOG_INFO(agent_logger, CTRL_AGENT_HTTPS_SERVICE_STARTED)
- .arg(server_address.toText()).arg(server_port);
+ .arg(server_address.toText())
+ .arg(server_port);
} else {
LOG_INFO(agent_logger, CTRL_AGENT_HTTP_SERVICE_STARTED)
- .arg(server_address.toText()).arg(server_port);
+ .arg(server_address.toText())
+ .arg(server_port);
}
});