|
1 | 1 | /*
|
2 |
| - * Copyright (c) 2000, 2023, Oracle and/or its affiliates. |
| 2 | + * Copyright (c) 2000, 2024, Oracle and/or its affiliates. |
3 | 3 | *
|
4 | 4 | * Licensed under the Universal Permissive License v 1.0 as shown at
|
5 | 5 | * https://oss.oracle.com/licenses/upl.
|
6 | 6 | */
|
7 | 7 | package topics;
|
8 | 8 |
|
| 9 | +import com.oracle.bedrock.options.Timeout; |
9 | 10 | import com.oracle.bedrock.runtime.coherence.CoherenceClusterMember;
|
10 | 11 | import com.oracle.bedrock.testsupport.deferred.Eventually;
|
11 | 12 | import com.oracle.coherence.common.util.Threads;
|
@@ -200,8 +201,8 @@ protected void shouldPubAndSub(ClosableCluster cluster, Version clusterVersion,
|
200 | 201 | try (CoherenceClusterMember memberPub = cluster.startPublisher("PublisherOne", pubSubVersion.getClassPath());
|
201 | 202 | CoherenceClusterMember memberSub = cluster.startSubscriber("SubscriberOne", pubSubVersion.getClassPath()))
|
202 | 203 | {
|
203 |
| - Eventually.assertDeferred(memberPub::isCoherenceRunning, is(true)); |
204 |
| - Eventually.assertDeferred(memberSub::isCoherenceRunning, is(true)); |
| 204 | + Eventually.assertDeferred(memberPub::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
| 205 | + Eventually.assertDeferred(memberSub::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
205 | 206 |
|
206 | 207 | String sTopicName = "test-topic";
|
207 | 208 | String sGroupName = "test-group";
|
@@ -234,9 +235,9 @@ protected void shouldPubWithMultipleSubs(ClosableCluster cluster, Version cluste
|
234 | 235 | CoherenceClusterMember memberSub1 = cluster.startSubscriber("SubscriberOne", pubSubVersion.getClassPath());
|
235 | 236 | CoherenceClusterMember memberSub2 = cluster.startSubscriber("SubscriberTwo", pubSubVersion.getClassPath()))
|
236 | 237 | {
|
237 |
| - Eventually.assertDeferred(memberPub::isCoherenceRunning, is(true)); |
238 |
| - Eventually.assertDeferred(memberSub1::isCoherenceRunning, is(true)); |
239 |
| - Eventually.assertDeferred(memberSub2::isCoherenceRunning, is(true)); |
| 238 | + Eventually.assertDeferred(memberPub::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
| 239 | + Eventually.assertDeferred(memberSub1::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
| 240 | + Eventually.assertDeferred(memberSub2::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
240 | 241 |
|
241 | 242 | String sTopicName = "test-topic";
|
242 | 243 | String sGroupName = "test-group";
|
@@ -284,9 +285,9 @@ protected void shouldPubWithMultipleSubsAndReallocation(ClosableCluster cluster,
|
284 | 285 | CoherenceClusterMember memberSub1 = cluster.startSubscriber("SubscriberOne", pubSubVersion.getClassPath());
|
285 | 286 | CoherenceClusterMember memberSub2 = cluster.startSubscriber("SubscriberTwo", pubSubVersion.getClassPath()))
|
286 | 287 | {
|
287 |
| - Eventually.assertDeferred(memberPub::isCoherenceRunning, is(true)); |
288 |
| - Eventually.assertDeferred(memberSub1::isCoherenceRunning, is(true)); |
289 |
| - Eventually.assertDeferred(memberSub2::isCoherenceRunning, is(true)); |
| 288 | + Eventually.assertDeferred(memberPub::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
| 289 | + Eventually.assertDeferred(memberSub1::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
| 290 | + Eventually.assertDeferred(memberSub2::isCoherenceRunning, is(true), Timeout.after(5, TimeUnit.MINUTES)); |
290 | 291 |
|
291 | 292 | cluster.log(">>>> Starting shouldPubWithMultipleSubsAndReallocation");
|
292 | 293 |
|
@@ -336,7 +337,7 @@ protected void shouldPubWithMultipleSubsAndReallocation(ClosableCluster cluster,
|
336 | 337 | cluster.log(">>>> In shouldPubWithMultipleSubsAndReallocation - closed subscribers");
|
337 | 338 |
|
338 | 339 | Eventually.assertDeferred(() -> TopicSubscriber.getChannelCount(memberSub1, "Sub1.2")
|
339 |
| - + TopicSubscriber.getChannelCount(memberSub2, "Sub2.2"), is(17)); |
| 340 | + + TopicSubscriber.getChannelCount(memberSub2, "Sub2.2"), is(17), Timeout.after(5, TimeUnit.MINUTES)); |
340 | 341 |
|
341 | 342 | cluster.log(">>>> In shouldPubWithMultipleSubsAndReallocation - subscriber have all channels");
|
342 | 343 |
|
|
0 commit comments