Hangleton commented on code in PR #13183: URL: https://github.com/apache/kafka/pull/13183#discussion_r1094454976
########## metadata/src/main/java/org/apache/kafka/metadata/migration/KRaftMigrationDriver.java: ########## @@ -474,6 +472,7 @@ class MetadataChangeEvent extends MigrationEvent { private final MetadataImage image; private final MetadataProvenance provenance; private final boolean isSnapshot; + CompletableFuture<Void> future = new CompletableFuture<>(); Review Comment: If we want to follow this pattern where the tests `KRaftMigrationDriverTest` are signalled when this event is processed, and at the same time avoid the cost of adding a future to every `SendRPCsToBrokersEvent`, `enqueueMetadataChangeEvent` could take a future in argument instead. Prod code would pass an empty/noop future. Alternatively the unit tests could loop until the assertions are verified or a timeout is reached. -- 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