apoorvmittal10 commented on code in PR #20837:
URL: https://github.com/apache/kafka/pull/20837#discussion_r2509864328


##########
core/src/main/java/kafka/server/share/SharePartition.java:
##########
@@ -1885,6 +1899,11 @@ private int acquireSubsetBatchRecords(
                     continue;
                 }
 
+                // If the record has any pending deliveries, return 
immediately and do not deliver the current bad record.
+                if (offsetState.getValue().deliveryCount() >= 
BAD_RECORD_DELIVERY_THRESHOLD && (hasBeenAcquired > 0 || acquiredCount > 0)) {
+                    return -acquiredCount;
+                }
+

Review Comment:
   Can you provide example in your PR description i.e. what exactly we have 
handled in the PR. The changes seems very confusing hence wanted to come to 
common understanding.



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