philipnee commented on code in PR #13380: URL: https://github.com/apache/kafka/pull/13380#discussion_r1133442329
########## clients/src/main/java/org/apache/kafka/clients/consumer/internals/CommitRequestManager.java: ########## @@ -149,6 +185,29 @@ Queue<StagedCommit> stagedCommits() { return this.stagedCommits; } + /** + * Get all the sendable requests, and create a list of UnsentRequest. + */ + private List<NetworkClientDelegate.UnsentRequest> sendOffsetFetchRequests(final long currentTimeMs) { + List<UnsentOffsetFetchRequestState> requests = unsentOffsetFetchRequests.sendableRequests(currentTimeMs); + List<NetworkClientDelegate.UnsentRequest> pollResults = new ArrayList<>(); Review Comment: I could also do it in request.stream().map().reduce(). Let me know if one way is better than the other. -- 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