[ https://issues.apache.org/jira/browse/HDFS-17713?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17936115#comment-17936115 ]
ASF GitHub Bot commented on HDFS-17713: --------------------------------------- hfutatzhanghb commented on code in PR #7304: URL: https://github.com/apache/hadoop/pull/7304#discussion_r1998206928 ########## hadoop-hdfs-project/hadoop-hdfs-rbf/src/main/java/org/apache/hadoop/hdfs/server/federation/router/async/RouterAsyncRpcClient.java: ########## @@ -479,6 +488,76 @@ public <T extends RemoteLocationContext, R> Map<T, R> invokeConcurrent( return asyncReturn(Map.class); } + @SuppressWarnings("unchecked") + public <T extends RemoteLocationContext, R> List<RemoteResult<T, R>> invokeConcurrent( + final Collection<T> locations, final RemoteMethod method, + boolean standby, long timeOutMs, + Class<R> clazz) throws IOException { + + final UserGroupInformation ugi = RouterRpcServer.getRemoteUser(); + final Method m = method.getMethod(); + + if (locations.isEmpty()) { + throw new IOException("No remote locations available"); + } else if (locations.size() == 1 && timeOutMs <= 0) { + // Shortcut, just one call + return invokeSingle(locations.iterator().next(), method); + } + // Don't acquire CONCURRENT_NS permit here. + RouterRpcFairnessPolicyController controller = getRouterRpcFairnessPolicyController(); + Review Comment: Do extra logic in RouterAsyncRpcFairnessPolicyController#acquirePermit. when nsid equals CONCURRENT_NS, return true and in RouterAsyncRpcFairnessPolicyController#releasePermit return immediately when nsid equals CONCURRENT_NS. > [ARR] Throtting asynchronous calls for each nameservice > ------------------------------------------------------- > > Key: HDFS-17713 > URL: https://issues.apache.org/jira/browse/HDFS-17713 > Project: Hadoop HDFS > Issue Type: Sub-task > Components: rbf > Reporter: farmmamba > Assignee: farmmamba > Priority: Major > Labels: pull-request-available > -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org