Jackie-Jiang commented on a change in pull request #7131: URL: https://github.com/apache/incubator-pinot/pull/7131#discussion_r664959301
########## File path: pinot-tools/src/main/java/org/apache/pinot/tools/admin/command/StartBrokerCommand.java ########## @@ -141,6 +136,13 @@ public boolean execute() Map<String, Object> properties = new HashMap<>(); if (_configFileName != null) { properties.putAll(PinotConfigUtils.readConfigFromFile(_configFileName)); + // Override the zkAddress and clusterName to ensure ServiceManager is connecting to the right Zookeeper and Cluster. + if (properties.containsKey(CommonConstants.Helix.CONFIG_OF_ZOOKEEPR_SERVER) && properties.get(CommonConstants.Helix.CONFIG_OF_ZOOKEEPR_SERVER) != null) { + _zkAddress = properties.get(CommonConstants.Helix.CONFIG_OF_ZOOKEEPR_SERVER).toString(); + } Review comment: Can be simplified, same for other places ```suggestion Object zkAddressProperty = properties.get(CommonConstants.Helix.CONFIG_OF_ZOOKEEPR_SERVER); if (zkAddressProperty != null) { _zkAddress = zkAddressProperty.toString(); } ``` -- 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-unsubscr...@pinot.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org