coderzc commented on code in PR #18407:
URL: https://github.com/apache/pulsar/pull/18407#discussion_r1019034946


##########
pulsar-client/src/main/java/org/apache/pulsar/client/impl/MultiTopicsConsumerImpl.java:
##########
@@ -458,7 +458,8 @@ protected CompletableFuture<Void> doAcknowledge(MessageId 
messageId, AckType ack
             Consumer individualConsumer = 
consumers.get(topicMessageId.getTopicPartitionName());
             if (individualConsumer != null) {
                 MessageId innerId = topicMessageId.getInnerMessageId();
-                return individualConsumer.acknowledgeCumulativeAsync(innerId);
+                return individualConsumer.acknowledgeCumulativeAsync(innerId)
+                        .thenAccept(__ -> 
unAckedMessageTracker.remove(topicMessageId));

Review Comment:
   ```suggestion
                           .thenAccept(__ -> 
unAckedMessageTracker.removeMessagesTill(topicMessageId));
   ```



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