clolov commented on code in PR #13180:
URL: https://github.com/apache/kafka/pull/13180#discussion_r1094398310


##########
metadata/src/main/java/org/apache/kafka/metadata/migration/KRaftMigrationDriver.java:
##########
@@ -415,7 +416,7 @@ public void run() throws Exception {
                             log.info("Migrating {} records from ZK", 
batch.size());
                         }
                         CompletableFuture<?> future = 
zkRecordConsumer.acceptBatch(batch);
-                        count.addAndGet(batch.size());
+                        summary.acceptBatch(batch);

Review Comment:
   I am new to this part of the codebase, so this might have an obvious answer, 
but previously we used an AtomicInteger, which leads me to believe there was a 
race-condition which the author was trying to avoid. If this is true, the new 
MigrationSummary class does not impose any synchronization barriers, is this 
correct?



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

Reply via email to