From cc3a2f69e04ee06fdd79d04f3b2422cc923707a5 Mon Sep 17 00:00:00 2001 From: "nikita.smirnov" Date: Fri, 12 Jul 2024 07:14:46 +0400 Subject: [PATCH] [TS-2413] Added logging --- src/main/java/com/exactpro/th2/FixHandler.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/exactpro/th2/FixHandler.java b/src/main/java/com/exactpro/th2/FixHandler.java index 6bb1d95..a84a3cf 100644 --- a/src/main/java/com/exactpro/th2/FixHandler.java +++ b/src/main/java/com/exactpro/th2/FixHandler.java @@ -1401,10 +1401,13 @@ private void transformProcessor( ByteBuf message, Map metadata ) { - Set disableForMessageTypes = strategy.getDisableForMessageTypes(); - FixField msgTypeField = findField(message, MSG_TYPE_TAG, US_ASCII); - if(msgTypeField == null || msgTypeField.getValue() == null || disableForMessageTypes.contains(msgTypeField.getValue())) { + if(msgTypeField == null || msgTypeField.getValue() == null) { + return; + } + Set disableForMessageTypes = strategy.getDisableForMessageTypes(); + if (disableForMessageTypes.contains(msgTypeField.getValue())) { + LOGGER.info("Strategy '{}' is disabled for {} message type", strategy.getType(), msgTypeField.getValue()); return; } @@ -1583,6 +1586,7 @@ private Map fakeRetransmissionOutgoingProcessor(ByteBuf message, Set disableForMessageTypes = strategy.getDisableForMessageTypes(); FixField msgTypeField = findField(message, MSG_TYPE_TAG, US_ASCII); if(msgTypeField != null && msgTypeField.getValue() != null && disableForMessageTypes.contains(msgTypeField.getValue())) { + LOGGER.info("Strategy '{}' is disabled for {} message type", strategy.getType(), msgTypeField.getValue()); return null; }