adixitconfluent commented on code in PR #20246:
URL: https://github.com/apache/kafka/pull/20246#discussion_r2448968387


##########
core/src/main/java/kafka/server/share/SharePartition.java:
##########
@@ -817,9 +832,13 @@ public ShareAcquiredRecords acquire(
                     // Do not send max fetch records to 
acquireSubsetBatchRecords as we want to acquire
                     // all the records from the batch as the batch will anyway 
be part of the file-records
                     // response batch.
-                    int acquiredSubsetCount = 
acquireSubsetBatchRecords(memberId, firstBatch.baseOffset(), 
lastOffsetToAcquire, inFlightBatch, result);
+                    int acquiredSubsetCount = 
acquireSubsetBatchRecords(memberId, isRecordLimitMode, maxFetchRecords, 
firstBatch.baseOffset(), lastOffsetToAcquire, inFlightBatch, result);
                     acquiredCount += acquiredSubsetCount;
-                    continue;
+                    if (isRecordLimitMode) {

Review Comment:
   I am not sure why do we need this piece of code, can you please add some 
comments why we need it?



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