]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#1087] Improved communication interrupted log
authorMarcin Siodelski <marcin@isc.org>
Mon, 18 May 2020 14:47:28 +0000 (16:47 +0200)
committerMarcin Siodelski <marcin@isc.org>
Wed, 20 May 2020 15:48:16 +0000 (17:48 +0200)
This log message now include server's name.

src/hooks/dhcp/high_availability/ha_messages.cc
src/hooks/dhcp/high_availability/ha_messages.h
src/hooks/dhcp/high_availability/ha_messages.mes
src/hooks/dhcp/high_availability/ha_service.cc

index 3167aaf4a76df94281e432c92d4c7c7c08eeca7f..65813e637294be5cc002113417a07873e510d287 100644 (file)
@@ -1,4 +1,4 @@
-// File created from ../../../../src/hooks/dhcp/high_availability/ha_messages.mes on Mon May 18 2020 11:51
+// File created from ../../../../src/hooks/dhcp/high_availability/ha_messages.mes on Mon May 18 2020 16:44
 
 #include <cstddef>
 #include <log/message_types.h>
@@ -101,7 +101,7 @@ const char* values[] = {
     "HA_BUFFER6_RECEIVE_PACKET_OPTIONS_SKIPPED", "an error upacking an option, caused subsequent options to be skipped: %1",
     "HA_BUFFER6_RECEIVE_UNPACK_FAILED", "failed to parse query from %1 to %2, received over interface %3, reason: %4",
     "HA_COMMAND_PROCESSED_FAILED", "command_processed callout failed: %1",
-    "HA_COMMUNICATION_INTERRUPTED", "communication is interrupted and failover process has been started",
+    "HA_COMMUNICATION_INTERRUPTED", "communication with %1 is interrupted",
     "HA_COMMUNICATION_INTERRUPTED_CLIENT4", "%1: new client attempting to get a lease from the partner",
     "HA_COMMUNICATION_INTERRUPTED_CLIENT4_UNACKED", "%1: partner server failed to respond, %2 clients unacked so far, %3 clients left before transitioning to the partner-down state",
     "HA_COMMUNICATION_INTERRUPTED_CLIENT6", "%1: new client attempting to get a lease from the partner",
index ca6769b8d34ec897b626db656452373a8d800b38..d1f6f67a75b9dd1a8c9cbf9987b9e06b4388a1b6 100644 (file)
@@ -1,4 +1,4 @@
-// File created from ../../../../src/hooks/dhcp/high_availability/ha_messages.mes on Mon May 18 2020 11:51
+// File created from ../../../../src/hooks/dhcp/high_availability/ha_messages.mes on Mon May 18 2020 16:44
 
 #ifndef HA_MESSAGES_H
 #define HA_MESSAGES_H
index 4c8f757fb5df215c12ed9297d98e1e5caba4b7d9..a8b16a226a31f4eaece73875e261048744fdfcdb 100644 (file)
@@ -58,7 +58,7 @@ reason for failure.
 This error message is issued when the callout for the command_processed hook
 point failed. The argument contains a reason for the error.
 
-% HA_COMMUNICATION_INTERRUPTED communication is interrupted and failover process has been started
+% HA_COMMUNICATION_INTERRUPTED communication with %1 is interrupted
 This warning message is issued by the server which discovered that the
 communication to the active partner has been interrupted for a time
 period longer than the configured heartbeat-delay time. At this stage
index a5ae0a93e89ee7d4344754895809d1db92216f13..1dbed9dfafdf3cc0424ff5d22fb36faea0bf04d9 100644 (file)
@@ -1351,7 +1351,8 @@ HAService::asyncSendHeartbeat() {
                 communication_state_->setPartnerState("unavailable");
                 // Log if the communication is interrupted.
                 if (communication_state_->isCommunicationInterrupted()) {
-                    LOG_WARN(ha_logger, HA_COMMUNICATION_INTERRUPTED);
+                    LOG_WARN(ha_logger, HA_COMMUNICATION_INTERRUPTED)
+                        .arg(partner_config->getName());
                 }
             }