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


##########
core/src/main/java/kafka/server/share/DelayedShareFetch.java:
##########
@@ -840,6 +842,14 @@ CompletableFuture<LinkedHashMap<TopicIdPartition, 
LogReadResult>> combineLogRead
             return CompletableFuture.completedFuture(existingFetchedData);
         }
 
+        // The already fetched records are handed out first, so only the 
remainder of the record budget
+        // is available to the missing partitions. If nothing remains then 
nothing from them could be
+        // acquired, so skip the read altogether; the partitions are simply 
absent from the response and
+        // their locks are released along with the rest of the acquired 
partitions.

Review Comment:
   The code actually does opposite of the comment. It puts missing first and 
then the existing ones



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