wangjialing218 commented on a change in pull request #13280:
URL: https://github.com/apache/pulsar/pull/13280#discussion_r768457549



##########
File path: 
pulsar-client/src/main/java/org/apache/pulsar/client/impl/MessageImpl.java
##########
@@ -76,6 +76,7 @@
     private BrokerEntryMetadata brokerEntryMetadata;
 
     private boolean poolMessage;
+    private boolean dlqMessage;

Review comment:
       Only retain byteBuf is not enough. We have to not call `recycle()` in 
`release()` if the message was added to `possibleSendToDeadLetterTopicMessages` 
list.
   
   If message is acked by consumer as normal case, the message will not be 
added to `possibleSendToDeadLetterTopicMessages` list and should be clear in 
`release()`.
   
   So how could we known whether this message was added to 
`possibleSendToDeadLetterTopicMessages` list when user call `release()`? If 
there is a way then we could remove this field.
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to