You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by kl...@apache.org on 2022/04/25 17:16:28 UTC

[geode] branch develop updated: GEODE-10209: Use AvailablePortHelper in InternalCacheForClientAccessDistributedTest (#7613)

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

klund pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode.git


The following commit(s) were added to refs/heads/develop by this push:
     new b594c842b7 GEODE-10209: Use AvailablePortHelper in InternalCacheForClientAccessDistributedTest (#7613)
b594c842b7 is described below

commit b594c842b7c8c2eff432206779b172dbf0650d51
Author: Kirk Lund <kl...@apache.org>
AuthorDate: Mon Apr 25 10:16:21 2022 -0700

    GEODE-10209: Use AvailablePortHelper in InternalCacheForClientAccessDistributedTest (#7613)
    
    Prevent BindException by using AvailablePortHelper.
---
 .../internal/cache/InternalCacheForClientAccessDistributedTest.java     | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/InternalCacheForClientAccessDistributedTest.java b/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/InternalCacheForClientAccessDistributedTest.java
index 67726502a4..9e88fa8774 100644
--- a/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/InternalCacheForClientAccessDistributedTest.java
+++ b/geode-core/src/distributedTest/java/org/apache/geode/internal/cache/InternalCacheForClientAccessDistributedTest.java
@@ -14,6 +14,7 @@
  */
 package org.apache.geode.internal.cache;
 
+import static org.apache.geode.internal.AvailablePortHelper.getRandomAvailableTCPPort;
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
 
@@ -75,6 +76,7 @@ public class InternalCacheForClientAccessDistributedTest implements java.io.Seri
       cache = serverCache;
 
       CacheServer cacheServer = serverCache.addCacheServer();
+      cacheServer.setPort(getRandomAvailableTCPPort());
       cacheServer.start();
     });
     clientVM.invoke(() -> {