You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by zh...@apache.org on 2021/10/25 17:49:30 UTC

[geode] 01/01: GEODE-9729: test should handle occasional AllConnectionsInUseException

This is an automated email from the ASF dual-hosted git repository.

zhouxj pushed a commit to branch feature/GEODE-9729
in repository https://gitbox.apache.org/repos/asf/geode.git

commit 89c03b3dd595b4ebcd31f782b8fddd6a07afb03a
Author: zhouxh <gz...@pivotal.io>
AuthorDate: Mon Oct 25 10:44:38 2021 -0700

    GEODE-9729: test should handle occasional AllConnectionsInUseException
---
 .../internal/cache/PartitionedRegionSingleHopDUnitTest.java    | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/PartitionedRegionSingleHopDUnitTest.java b/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/PartitionedRegionSingleHopDUnitTest.java
index 43019bf..fa6a22e 100755
--- a/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/PartitionedRegionSingleHopDUnitTest.java
+++ b/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/PartitionedRegionSingleHopDUnitTest.java
@@ -938,7 +938,10 @@ public class PartitionedRegionSingleHopDUnitTest implements Serializable {
     Region<Object, Object> partitionedRegion = getRegion(PARTITIONED_REGION_NAME);
 
     await().until(() -> {
-      clientMetadataService.getClientPRMetadata((InternalRegion) partitionedRegion);
+      try {
+        clientMetadataService.getClientPRMetadata((InternalRegion) partitionedRegion);
+      } catch (AllConnectionsInUseException ignore) {
+      }
 
       Map<ServerLocation, Set<Integer>> serverBucketMap =
           clientMetadataService.groupByServerToAllBuckets(partitionedRegion, true);
@@ -969,7 +972,10 @@ public class PartitionedRegionSingleHopDUnitTest implements Serializable {
     createServerOnVM0.await();
 
     await().untilAsserted(() -> {
-      clientMetadataService.getClientPRMetadata((InternalRegion) partitionedRegion);
+      try {
+        clientMetadataService.getClientPRMetadata((InternalRegion) partitionedRegion);
+      } catch (AllConnectionsInUseException ignore) {
+      }
       Map<ServerLocation, Set<Integer>> serverBucketMap =
           clientMetadataService.groupByServerToAllBuckets(partitionedRegion, true);