From 0ddd55b2ccdbb182a062a4334318af13e765e891 Mon Sep 17 00:00:00 2001 From: Justin Bertram Date: Tue, 29 Oct 2019 10:13:03 -0500 Subject: [PATCH] NO-JIRA add acceptor to handshake timeout msg --- .../activemq/artemis/core/protocol/ProtocolHandler.java | 2 +- .../activemq/artemis/core/server/ActiveMQServerLogger.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/ProtocolHandler.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/ProtocolHandler.java index 387e9e670e..c12aa5a8d8 100644 --- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/ProtocolHandler.java +++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/ProtocolHandler.java @@ -116,7 +116,7 @@ public class ProtocolHandler { public void channelActive(ChannelHandlerContext ctx) throws Exception { if (handshakeTimeout > 0) { timeoutFuture = scheduledThreadPool.schedule( () -> { - ActiveMQServerLogger.LOGGER.handshakeTimeout(handshakeTimeout, ctx.channel().remoteAddress().toString()); + ActiveMQServerLogger.LOGGER.handshakeTimeout(handshakeTimeout, nettyAcceptor.getName(), ctx.channel().remoteAddress().toString()); ctx.channel().close(); }, handshakeTimeout, TimeUnit.SECONDS); } diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java index 4952fce92a..0d8a48ebc5 100644 --- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java +++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java @@ -1973,8 +1973,8 @@ public interface ActiveMQServerLogger extends BasicLogger { void errorAnnouncingBackup(String backupManager); @LogMessage(level = Logger.Level.ERROR) - @Message(id = 224088, value = "Timeout ({0} seconds) while handshaking with {1} has occurred.", format = Message.Format.MESSAGE_FORMAT) - void handshakeTimeout(int timeout, String remoteAddress); + @Message(id = 224088, value = "Timeout ({0} seconds) on acceptor \"{1}\" during protocol handshake with {2} has occurred.", format = Message.Format.MESSAGE_FORMAT) + void handshakeTimeout(int timeout, String acceptorName, String remoteAddress); @LogMessage(level = Logger.Level.WARN) @Message(id = 224089, value = "Failed to calculate persistent size", format = Message.Format.MESSAGE_FORMAT)