chengyouling commented on code in PR #4486:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/4486#discussion_r1740294152


##########
clients/http-client-common/src/main/java/org/apache/servicecomb/http/client/common/AbstractAddressManager.java:
##########
@@ -98,25 +91,33 @@ public class AbstractAddressManager {
   public AbstractAddressManager(List<String> addresses) {
     this.projectName = DEFAULT_PROJECT;
     this.addresses.addAll(addresses);
-    this.defaultAddress.addAll(addresses);
-    this.index = addresses.size() > 0 ? random.nextInt(addresses.size()) : 0;
+    this.addressCategory.addAll(addresses);
+    this.index = !addresses.isEmpty() ? random.nextInt(addresses.size()) : 0;

Review Comment:
   only default scene use addressCategory for address choose in address() 
method, and in this scence, addresses and addressCategory may have same size



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to