kirklund commented on code in PR #7493:
URL: https://github.com/apache/geode/pull/7493#discussion_r857812194


##########
geode-core/src/distributedTest/java/org/apache/geode/internal/cache/execute/PRClientServerTestBase.java:
##########
@@ -489,6 +525,22 @@ void createClientServerScenarioNoSingleHop(ArrayList 
commonAttributes,
         NetworkUtils.getServerHostName(server1.getHost()), port1, port2, 
port3));
   }
 
+  void createClientServerScenarioNoSingleHop(ArrayList commonAttributes,
+      int localMaxMemoryServer1, int localMaxMemoryServer2,
+      int localMaxMemoryServer3,
+      int maxThreads,
+      int connectTimeout) {
+    createCacheInClientServer();
+    Integer port1 = server1.invoke(() -> PRClientServerTestBase
+        .createCacheServer(commonAttributes, localMaxMemoryServer1, 
maxThreads));
+    Integer port2 = server2.invoke(() -> PRClientServerTestBase
+        .createCacheServer(commonAttributes, localMaxMemoryServer2, 
maxThreads));
+    Integer port3 = server3.invoke(() -> PRClientServerTestBase
+        .createCacheServer(commonAttributes, localMaxMemoryServer3, 
maxThreads));
+    client.invoke(() -> PRClientServerTestBase.createNoSingleHopCacheClient(
+        NetworkUtils.getServerHostName(server1.getHost()), port1, port2, 
port3, connectTimeout));

Review Comment:
   A few minor nitpicks here (comment only):
   
   1. Change those `Integer` vars to `int` and prefer primitives to wrapper 
types if possible.
   2. I recommend using `String` hostname instance fields instead inlining 
those `getServerHostName` and `getHost` calls in the RMI lambdas. Some of them 
misbehave when called in the dunit `ChildVMs` so this avoids all issues.



-- 
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: notifications-unsubscr...@geode.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to