ijuma commented on a change in pull request #9206:
URL: https://github.com/apache/kafka/pull/9206#discussion_r492865230



##########
File path: core/src/main/scala/kafka/log/LogValidator.scala
##########
@@ -234,17 +234,16 @@ private[log] object LogValidator extends Logging {
 
     val firstBatch = getFirstBatchAndMaybeValidateNoMoreBatches(records, 
NoCompressionCodec)
 
-    records.batches.forEach { batch =>
+    for (batch <- records.batches.asScala) {

Review comment:
       I liked your changes to make the code more concise, I'd keep them.




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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to