zhouxinyu commented on a change in pull request #255: [ISSUE #254] Add message 
statistical log on DLQ for security audit
URL: https://github.com/apache/rocketmq/pull/255#discussion_r177699385
 
 

 ##########
 File path: 
broker/src/main/java/org/apache/rocketmq/broker/processor/SendMessageProcessor.java
 ##########
 @@ -190,6 +195,11 @@ private RemotingCommand consumerSendMsgBack(final 
ChannelHandlerContext ctx, fin
                 response.setRemark("topic[" + newTopic + "] not exist");
                 return response;
             }
+            String msgId = 
msgExt.getProperty(MessageConst.PROPERTY_UNIQ_CLIENT_MESSAGE_ID_KEYIDX);
+            if (msgId == null) {
+                msgId = 
msgExt.getProperty(MessageConst.PROPERTY_ORIGIN_MESSAGE_ID);
+            }
+            dlqLogger.info("[DLQ] topic:" + retryTopic + " consumerGroup:" + 
requestHeader.getGroup() + " msgId:" + msgId);
 
 Review comment:
   Can we use the format version of info? like: `log.info("Topic: {}", topic)`?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to