This is an automated email from the ASF dual-hosted git repository. hyunkun pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/dubbo.git
The following commit(s) were added to refs/heads/master by this push: new 39edc80 fix some typos in LeastActiveLoadBalance (#5044) 39edc80 is described below commit 39edc80716aaa998eedcc53a2997fa5f7ac2b0ae Author: LHearen <lhea...@gmail.com> AuthorDate: Wed Sep 11 12:01:46 2019 +0800 fix some typos in LeastActiveLoadBalance (#5044) --- .../dubbo/rpc/cluster/loadbalance/LeastActiveLoadBalance.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveLoadBalance.java b/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveLoadBalance.java index 0706053..f9283fb 100644 --- a/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveLoadBalance.java +++ b/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveLoadBalance.java @@ -48,9 +48,9 @@ public class LeastActiveLoadBalance extends AbstractLoadBalance { int[] leastIndexes = new int[length]; // the weight of every invokers int[] weights = new int[length]; - // The sum of the warmup weights of all the least active invokes + // The sum of the warmup weights of all the least active invokers int totalWeight = 0; - // The weight of the first least active invoke + // The weight of the first least active invoker int firstWeight = 0; // Every least active invoker has the same weight value? boolean sameWeight = true; @@ -59,9 +59,9 @@ public class LeastActiveLoadBalance extends AbstractLoadBalance { // Filter out all the least active invokers for (int i = 0; i < length; i++) { Invoker<T> invoker = invokers.get(i); - // Get the active number of the invoke + // Get the active number of the invoker int active = RpcStatus.getStatus(invoker.getUrl(), invocation.getMethodName()).getActive(); - // Get the weight of the invoke configuration. The default value is 100. + // Get the weight of the invoker's configuration. The default value is 100. int afterWarmup = getWeight(invoker, invocation); // save for later use weights[i] = afterWarmup; @@ -113,4 +113,4 @@ public class LeastActiveLoadBalance extends AbstractLoadBalance { // If all invokers have the same weight value or totalWeight=0, return evenly. return invokers.get(leastIndexes[ThreadLocalRandom.current().nextInt(leastCount)]); } -} \ No newline at end of file +}