eolivelli commented on a change in pull request #9583:
URL: https://github.com/apache/pulsar/pull/9583#discussion_r575797734
##########
File path:
pulsar-client/src/main/java/org/apache/pulsar/client/impl/ConsumerImpl.java
##########
@@ -672,10 +673,17 @@ public UnAckedMessageTracker getUnAckedMessageTracker() {
@Override
public void negativeAcknowledge(MessageId messageId) {
- negativeAcksTracker.add(messageId);
+ if (getSubType() != SubType.Key_Shared) {
+ negativeAcksTracker.add(messageId);
- // Ensure the message is not redelivered for ack-timeout, since we did
receive an "ack"
- unAckedMessageTracker.remove(messageId);
+ // Ensure the message is not redelivered for ack-timeout, since we
did receive an "ack"
+ unAckedMessageTracker.remove(messageId);
+ } else {
+ if (log.isDebugEnabled()) {
+ log.debug("NegativeAcknowledge for Key_Shared subscription
type for message {} is ignored as this will" +
Review comment:
Why aren't we throwing an error?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]