You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/07/13 13:04:55 UTC

[GitHub] [pulsar] Nicklee007 commented on a diff in pull request #16573: [fix][broker]fix the zero value as denominator cause ArithmeticException when selectBroker use LeastResourceUsageWithWeight

Nicklee007 commented on code in PR #16573:
URL: https://github.com/apache/pulsar/pull/16573#discussion_r920053672


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/loadbalance/impl/LeastResourceUsageWithWeight.java:
##########
@@ -125,6 +125,11 @@ private double updateAndGetMaxResourceUsageWithWeight(String broker, BrokerData
     @Override
     public Optional<String> selectBroker(Set<String> candidates, BundleData bundleToAssign, LoadData loadData,

Review Comment:
   it can not permit after invoke `applyNamespacePolicies`  candidates is not empty. there may be not any one broker satisfy the NamespacePolicies for the namespace.



-- 
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-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org