Skip to content

Commit fa5c617

Browse files
poorbarcodemukesh-ctds
authored andcommitted
[fix][test] Fix flaky test OneWayReplicatorUsingGlobalZKTest.testConfigReplicationStartAt (apache#24011)
(cherry picked from commit 8b196d8) (cherry picked from commit c05e998)
1 parent 1309c9a commit fa5c617

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pulsar-broker/src/test/java/org/apache/pulsar/broker/service/OneWayReplicatorUsingGlobalZKTest.java

+4
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,10 @@ public void testConfigReplicationStartAt() throws Exception {
156156
p1.close();
157157

158158
admin1.namespaces().setNamespaceReplicationClusters(ns1, new HashSet<>(Arrays.asList(cluster1, cluster2)));
159+
Awaitility.await().untilAsserted(() -> {
160+
assertTrue(admin2.topics().getList(ns1).contains(topic1));
161+
});
162+
admin2.topics().createSubscription(topic1, subscription1, MessageId.earliest);
159163
org.apache.pulsar.client.api.Consumer<String> c1 = client2.newConsumer(Schema.STRING).topic(topic1)
160164
.subscriptionName(subscription1).subscribe();
161165
Message<String> msg2 = c1.receive(2, TimeUnit.SECONDS);

0 commit comments

Comments
 (0)