showuon commented on code in PR #12066: URL: https://github.com/apache/kafka/pull/12066#discussion_r854747258
########## clients/src/main/java/org/apache/kafka/clients/producer/internals/RecordAccumulator.java: ########## @@ -566,6 +565,8 @@ private List<ProducerBatch> drainBatchesForOneNode(Cluster cluster, Node node, i do { PartitionInfo part = parts.get(drainIndex); TopicPartition tp = new TopicPartition(part.topic(), part.partition()); + updateDrainIndex(node.idString(), drainIndex); + drainIndex = (drainIndex + 1) % parts.size(); Review Comment: Thanks, and please add a test for the `continue` case. 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org