codelipenghui commented on code in PR #15391:
URL: https://github.com/apache/pulsar/pull/15391#discussion_r867850751
##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/AbstractBaseDispatcher.java:
##########
@@ -227,6 +236,15 @@ && trackDelayedDelivery(entry.getLedgerId(),
entry.getEntryId(), msgMetadata)) {
((AbstractTopic) topic).addFilteredEntriesCount(filtered);
}
}
+ if (CollectionUtils.isNotEmpty(entriesToRedeliver)) {
+
this.subscription.getTopic().getBrokerService().getPulsar().getExecutor()
+ .schedule(() -> {
+ // simulate the Consumer rejected the message
+ subscription
+ .redeliverUnacknowledgedMessages(consumer,
entriesToRedeliver);
+ }, 1, TimeUnit.SECONDS);
+
+ }
Review Comment:
But for a single active consumer, it will rewind the cursor multiple times.
It's not like Shared subscription(only redeliver the given message)
--
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]