jackjlli commented on a change in pull request #7127:
URL: https://github.com/apache/incubator-pinot/pull/7127#discussion_r664775710



##########
File path: 
pinot-controller/src/main/java/org/apache/pinot/controller/BaseControllerStarter.java
##########
@@ -161,10 +162,18 @@ public void init(PinotConfiguration pinotConfiguration)
     inferHostnameIfNeeded(_config);
     _hostname = _config.getControllerHost();
     _port = _listenerConfigs.get(0).getPort();
+    // NOTE: Use <hostname>_<port> as Helix controller instance id because 
ControllerLeaderLocator relies on this format
+    //       to parse the leader controller's hostname and port
+    // TODO: Use the same instance id for controller and participant when 
leadControllerResource is always enabled after
+    //       releasing 0.8.0 when

Review comment:
       redundant `when`?

##########
File path: 
pinot-core/src/main/java/org/apache/pinot/core/transport/ServerInstance.java
##########
@@ -19,17 +19,17 @@
 package org.apache.pinot.core.transport;
 
 import com.google.common.annotations.VisibleForTesting;
+import org.apache.commons.lang.StringUtils;
 import org.apache.helix.model.InstanceConfig;
 import org.apache.pinot.spi.config.table.TableType;
 import org.apache.pinot.spi.utils.CommonConstants.Helix;
 
 
 public class ServerInstance {
-  private static final int SERVER_INSTANCE_PREFIX_LENGTH = 
Helix.PREFIX_OF_SERVER_INSTANCE.length();
-  private static final String HOSTNAME_PORT_DELIMITER = "_";
+  private static final char HOSTNAME_PORT_DELIMITER = '_';
 
   private final String _hostname;
-  private final int _port;
+  private int _port;

Review comment:
       Why removing the `final` here?




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

Reply via email to