You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@helix.apache.org by GitBox <gi...@apache.org> on 2019/11/18 22:56:46 UTC

[GitHub] [helix] kaisun2000 commented on a change in pull request #606: Modify ZkUtil methods so that they accept ZkAddress as parameter

kaisun2000 commented on a change in pull request #606: Modify ZkUtil methods so that they accept ZkAddress as parameter
URL: https://github.com/apache/helix/pull/606#discussion_r347653407
 
 

 ##########
 File path: helix-core/src/main/java/org/apache/helix/manager/zk/ZKUtil.java
 ##########
 @@ -42,6 +43,14 @@
   private ZKUtil() {
   }
 
+  public static boolean isClusterSetup(String clusterName, String zkAddress) {
+    HelixZkClient zkClient = getHelixZkClient(zkAddress);
+    boolean result = isClusterSetup(clusterName, zkClient);
+    zkClient.close();
 
 Review comment:
   > I buy the idea of one time access of different ZKs. But I think we should do following things:
   > 
   > 1. Make clear Java doc to let user understand it could cause more resource usage (ZKClient open/close).
   > 2. We should not deprecate the old API as long as that can provide user an option to now open/close ZKClient frequently while they would like to use the similar functionalities.
   > 
   > Also we need to clearly define the role of this Util and follow the rule for future development.
   
   @dasahcc, actually we are targeting to hide ZkClient from Helix powered applications. So that later they don't see them anymore. Instead, they see HelixManager, HelixAdmin, ConfigAccessor, HelixDataAccessor, HelixPropertyStore, HelixVerifiyer and the last one is ZkUtil.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org