You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "xiangfu0 (via GitHub)" <gi...@apache.org> on 2023/11/01 05:08:07 UTC

Re: [PR] Randomize zookeeper port for test [pinot]

xiangfu0 commented on code in PR #11911:
URL: https://github.com/apache/pinot/pull/11911#discussion_r1378398157


##########
pinot-controller/src/test/java/org/apache/pinot/controller/helix/ControllerTest.java:
##########
@@ -181,9 +181,15 @@ public ControllerRequestClient getControllerRequestClient() {
     return _controllerRequestClient;
   }
 
+  public void startDefaultTestZk() {
+    if (_zookeeperInstance == null) {
+      _zookeeperInstance = ZkStarter.startLocalZkServer(ZkStarter.DEFAULT_ZK_TEST_PORT);
+    }
+  }
+
   public void startZk() {
     if (_zookeeperInstance == null) {
-      _zookeeperInstance = ZkStarter.startLocalZkServer();
+      _zookeeperInstance = ZkStarter.startLocalZkServer(NetUtils.findOpenPort(20000 + RandomUtils.nextInt(10000)));

Review Comment:
   no, just random picked.



-- 
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: commits-unsubscribe@pinot.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org