mimaison commented on a change in pull request #9029: URL: https://github.com/apache/kafka/pull/9029#discussion_r459460614
########## File path: connect/mirror/src/test/java/org/apache/kafka/connect/mirror/MirrorConnectorsIntegrationTest.java ########## @@ -62,6 +65,7 @@ private static final int NUM_PARTITIONS = 10; private static final int RECORD_TRANSFER_DURATION_MS = 20_000; private static final int CHECKPOINT_DURATION_MS = 20_000; + private static final int OFFSET_SYNC_DURATION_MS = 30_000; private Time time = Time.SYSTEM; Review comment: We can remove this field now that it's unused ########## File path: connect/mirror/src/test/java/org/apache/kafka/connect/mirror/MirrorConnectorsIntegrationTest.java ########## @@ -315,9 +319,34 @@ public void testReplication() throws InterruptedException { backup.kafka().consume(NUM_RECORDS_PRODUCED, 2 * RECORD_TRANSFER_DURATION_MS, "primary.test-topic-2").count()); } + private void waitForConsumerGroupOffsetSync(Consumer<byte[], byte[]> consumer, List<String> topics, String consumerGroupId) + throws InterruptedException { + Admin backupClient = backup.kafka().createAdminClient(); + List<TopicPartition> tps = new ArrayList<>(NUM_PARTITIONS * topics.size()); + IntStream.range(0, NUM_PARTITIONS).forEach( Review comment: I'm not sure this is much better than a simple `for` loop. WDYT? ---------------------------------------------------------------- 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