merlimat commented on a change in pull request #12946:
URL: https://github.com/apache/pulsar/pull/12946#discussion_r755274729



##########
File path: 
pulsar-client/src/main/java/org/apache/pulsar/client/impl/ConsumerImpl.java
##########
@@ -624,8 +624,8 @@ public UnAckedMessageTracker getUnAckedMessageTracker() {
                     if (message.hasKey()) {
                         typedMessageBuilderNew.key(message.getKey());
                     }
-                    typedMessageBuilderNew.send();
-                    return doAcknowledge(messageId, ackType, properties, null);
+                    return typedMessageBuilderNew.sendAsync().thenAccept(__ ->

Review comment:
       We should add `exceptionally()` section to handle the 
`CompletableFuture` failure and do negative-ack again on the 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]


Reply via email to