You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@helix.apache.org by GitBox <gi...@apache.org> on 2019/09/11 17:31:33 UTC
[GitHub] [helix] jiajunwang commented on a change in pull request #456: Add
delayed rebalance and user-defined preference list features to the WAGED
rebalancer.
jiajunwang commented on a change in pull request #456: Add delayed rebalance and user-defined preference list features to the WAGED rebalancer.
URL: https://github.com/apache/helix/pull/456#discussion_r323367650
##########
File path: helix-core/src/main/java/org/apache/helix/controller/rebalancer/waged/WagedRebalancer.java
##########
@@ -139,6 +141,11 @@ protected WagedRebalancer(AssignmentMetadataStore assignmentMetadataStore,
// Calculate the target assignment based on the current cluster status.
Map<String, IdealState> newIdealStates = computeBestPossibleStates(clusterData, resourceMap);
+ // Apply user-defined preference list after the calculation.
+ // Note the user-defined list will be applied as an overwritten to the final result, instead of
+ // part of the rebalance algorithm.
+ newIdealStates.entrySet().stream().forEach(idealStateEntry -> applyUserDefinePreferenceList(
Review comment:
In the calculation, the assignment will be persisted into the AssignmentMetadata store. This will impact the calculation. If we want to treat the user-defined list as a temporary config, we shall not persist it.
It is debatable. So let me what's your thought here.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org