You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2020/10/09 09:13:10 UTC

[GitHub] [incubator-pinot] KKcorps commented on a change in pull request #6119: Change Signature of Broker API in Controller

KKcorps commented on a change in pull request #6119:
URL: https://github.com/apache/incubator-pinot/pull/6119#discussion_r502295997



##########
File path: pinot-common/src/main/java/org/apache/pinot/common/utils/helix/HelixHelper.java
##########
@@ -422,10 +423,15 @@ public IdealState apply(@Nullable IdealState idealState) {
    * reuse instance configs in order to reduce ZK accesses
    */
   public static List<String> getInstancesWithTag(List<InstanceConfig> instanceConfigs, String tag) {
-    List<String> instancesWithTag = new ArrayList<>();
+    List<InstanceConfig> instancesWithTag = getInstancesConfigsWithTag(instanceConfigs, tag);
+    return instancesWithTag.stream().map(InstanceConfig::getInstanceName).collect(Collectors.toList());

Review comment:
       These APIs won't be called frequently. The only use of this API is to determine brokers for a tenant or table while creating a connection for a query. Once the connection is created, the API is only called again if the connection breaks.




----------------------------------------------------------------
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: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org