heesung-sn commented on code in PR #20948:
URL: https://github.com/apache/pulsar/pull/20948#discussion_r1310515500


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/persistent/MessageDeduplication.java:
##########
@@ -387,8 +411,10 @@ public void recordMessagePersisted(PublishContext 
publishContext, PositionImpl p
             sequenceId = publishContext.getOriginalSequenceId();
             highestSequenceId = publishContext.getOriginalHighestSequenceId();
         }
-
-        highestSequencedPersisted.put(producerName, 
Math.max(highestSequenceId, sequenceId));
+        Boolean isLastChunk = (Boolean) 
publishContext.getProperty(IS_LAST_CHUNK);

Review Comment:
   Do we share this IS_LAST_CHUNK context property with other classes or 
functions? If it is used only in this func, can't we simply define it like this 
here
   `boolean isLastChunk = chunkID != -1 && chunkID == totalChunk - 1;`?



-- 
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