chia7712 commented on code in PR #20745:
URL: https://github.com/apache/kafka/pull/20745#discussion_r2453805016
##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/AbstractFetch.java:
##########
@@ -341,15 +341,15 @@ protected FetchRequest.Builder createFetchRequest(final
Node fetchTarget,
* until the previously-fetched data has been processed.
*
* @param buffered The set of partitions we have in our buffer
- * @return {@link Set} of {@link TopicPartition topic partitions} for
which we should fetch data
+ * @return {@link List} of {@link TopicPartition topic partitions} for
which we should fetch data
*/
- private Set<TopicPartition> fetchablePartitions(Set<TopicPartition>
buffered) {
+ private List<TopicPartition> fetchablePartitions(Set<TopicPartition>
buffered) {
// This is the test that returns true if the partition is *not*
buffered
Predicate<TopicPartition> isNotBuffered = tp -> !buffered.contains(tp);
// Return all partitions that are in an otherwise fetchable state
*and* for which we don't already have some
// messages sitting in our buffer.
- return new HashSet<>(subscriptions.fetchablePartitions(isNotBuffered));
+ return subscriptions.fetchablePartitions(isNotBuffered);
Review Comment:
@kirktrue do you have free cycle to take a look at this change? 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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]