ShivsundarR commented on code in PR #18419:
URL: https://github.com/apache/kafka/pull/18419#discussion_r1906983017


##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/ShareConsumeRequestManager.java:
##########
@@ -1169,15 +1169,17 @@ class ResultHandler {
          * signal the completion when all results are known.
          */
         public void complete(TopicIdPartition partition, Acknowledgements 
acknowledgements, boolean isCommitAsync) {
-            if (acknowledgements != null) {
-                result.put(partition, acknowledgements);
-            }
             // For commitAsync, we do not wait for other results to complete, 
we prepare a background event
             // for every ShareAcknowledgeResponse.
             // For commitAsync, we send out a background event for every 
TopicIdPartition, so we use a singletonMap each time.
             if (isCommitAsync) {
-                
maybeSendShareAcknowledgeCommitCallbackEvent(Collections.singletonMap(partition,
 acknowledgements));
+                if (acknowledgements != null) {

Review Comment:
   Yeah makes sense, I have added tests now for that. Thanks.



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to