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 2020/08/10 20:57:27 UTC

[GitHub] [helix] dasahcc commented on a change in pull request #1243: Make HelixCustomCodeRunner multi-ZK aware

dasahcc commented on a change in pull request #1243:
URL: https://github.com/apache/helix/pull/1243#discussion_r468181491



##########
File path: helix-core/src/main/java/org/apache/helix/participant/HelixCustomCodeRunner.java
##########
@@ -130,14 +147,23 @@ public void start() throws Exception {
 
     StateMachineEngine stateMach = _manager.getStateMachineEngine();
     stateMach.registerStateModelFactory(LEADER_STANDBY, _stateModelFty, _resourceName);
-    HelixZkClient zkClient = null;
+    RealmAwareZkClient zkClient = null;
     try {
       // manually add ideal state for participant leader using LeaderStandby
       // model
-      HelixZkClient.ZkClientConfig clientConfig = new HelixZkClient.ZkClientConfig();
-      clientConfig.setZkSerializer(new ZNRecordSerializer());
-      zkClient = SharedZkClientFactory.getInstance()
-          .buildZkClient(new HelixZkClient.ZkConnectionConfig(_zkAddr), clientConfig);
+      if (Boolean.getBoolean(SystemPropertyKeys.MULTI_ZK_ENABLED) || _zkAddr == null) {

Review comment:
       if zkaddress is null and we are initialize it with FederatedZKClient, do we have problem? For example, we cannot get the routing key and cause any problems?




----------------------------------------------------------------
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



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