mimaison commented on code in PR #12804:
URL: https://github.com/apache/kafka/pull/12804#discussion_r1012093538


##########
connect/mirror/src/test/java/org/apache/kafka/connect/mirror/integration/MirrorConnectorsIntegrationBaseTest.java:
##########
@@ -640,11 +645,7 @@ protected static void 
waitUntilMirrorMakerIsRunning(EmbeddedConnectCluster conne
      * wait for the topic created on the cluster
      */
     protected static void waitForTopicCreated(EmbeddedConnectCluster cluster, 
String topicName) throws InterruptedException {
-        try (final Admin adminClient = cluster.kafka().createAdminClient()) {
-            waitForCondition(() -> 
adminClient.listTopics().names().get().contains(topicName), 
TOPIC_SYNC_DURATION_MS,
-                "Topic: " + topicName + " didn't get created on cluster: " + 
cluster.getName()
-            );
-        }
+        waitForTopicCreated(cluster.kafka(), topicName);

Review Comment:
   Actually I wonder if we should delete the other `waitForTopicCreated()` 
method instead as it only has a single caller, and the caller can just use 
`backup` instead of `backup.kafka()`. 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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to