himanshukandwal commented on code in PR #2639:
URL: https://github.com/apache/helix/pull/2639#discussion_r1344684197
##########
helix-core/src/main/java/org/apache/helix/controller/rebalancer/waged/constraints/ConstraintBasedAlgorithm.java:
##########
@@ -120,24 +120,24 @@ public OptimalAssignment calculate(ClusterModel
clusterModel) throws HelixRebala
private Optional<AssignableNode> getNodeWithHighestPoints(AssignableReplica
replica,
List<AssignableNode> assignableNodes, ClusterContext clusterContext,
Set<String> busyInstances, OptimalAssignment optimalAssignment) {
- Map<AssignableNode, List<HardConstraint>> hardConstraintFailures = new
ConcurrentHashMap<>();
+ Map<AssignableNode, List<String>> hardConstraintFailures = new
ConcurrentHashMap<>();
List<AssignableNode> candidateNodes =
assignableNodes.parallelStream().filter(candidateNode -> {
boolean isValid = true;
// need to record all the failure reasons and it gives us the ability to
debug/fix the runtime
// cluster environment
for (HardConstraint hardConstraint : _hardConstraints) {
- if (!hardConstraint.isAssignmentValid(candidateNode, replica,
clusterContext)) {
+ ValidationResult validationResult =
hardConstraint.isAssignmentValid(candidateNode, replica, clusterContext);
Review Comment:
Got it. I will then overload this function.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]