Get the MinActiveReplica from Resource Config and Idea State#878
Merged
jiajunwang merged 4 commits intoapache:masterfrom Mar 11, 2020
Merged
Get the MinActiveReplica from Resource Config and Idea State#878jiajunwang merged 4 commits intoapache:masterfrom
jiajunwang merged 4 commits intoapache:masterfrom
Conversation
narendly
reviewed
Mar 9, 2020
helix-core/src/main/java/org/apache/helix/model/ResourceConfig.java
Outdated
Show resolved
Hide resolved
added 4 commits
March 10, 2020 10:59
…rebalance. Currently, the same configuration item can be configured in both Resource Config and Ideal State. In theory, the Resource Config is the right place. This is the first step to migrate the IdealState usage to read the Resource Config. Moving forward, IdealState should not be a method for the controller to take input. And any ideal state update to the IS nodes won't trigger a rebalance pipeline.
…ctiveReplica() before we fully migrate the configs to the resource config to avoid incorrect usage.
junkaixue
reviewed
Mar 10, 2020
narendly
approved these changes
Mar 11, 2020
Contributor
Author
|
This PR is ready to be merged, approved by @narendly |
zhangmeng916
pushed a commit
to zhangmeng916/helix
that referenced
this pull request
Apr 4, 2020
…rebalance. (apache#878) * Currently, the same configuration item can be configured in both Resource Config and Ideal State. In theory, the Resource Config is the right place. This is the first step to migrate the IdealState usage to read the Resource Config. Moving forward, IdealState should not be a method for the controller to take input. And any ideal state update to the IS nodes won't trigger a rebalance pipeline. * Add setXXXIfAbsent methods to the ZNRecord for simplifying code. * Add redundant parameter IdealState to the DelayedRebalanceUtil.getMinActiveReplica() before we fully migrate the configs to the resource config to avoid incorrect usage.
huizhilu
pushed a commit
to huizhilu/helix
that referenced
this pull request
Aug 16, 2020
…rebalance. (apache#878) * Currently, the same configuration item can be configured in both Resource Config and Ideal State. In theory, the Resource Config is the right place. This is the first step to migrate the IdealState usage to read the Resource Config. Moving forward, IdealState should not be a method for the controller to take input. And any ideal state update to the IS nodes won't trigger a rebalance pipeline. * Add setXXXIfAbsent methods to the ZNRecord for simplifying code. * Add redundant parameter IdealState to the DelayedRebalanceUtil.getMinActiveReplica() before we fully migrate the configs to the resource config to avoid incorrect usage.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issues
#877
Description
Read the MinActiveReplica config from both Resource Config and Idea State.
Currently, the same configuration item can be configured in both Resource Config and Ideal State. In theory, the Resource Config is the right place.
This is the first step to migrate the IdealState usage to read the Resource Config.
Tests
TestResourceConfig.testMergeWithIdealState
Results :
Failed tests:
org.apache.helix.integration.rebalancer.CrushRebalancers.TestCrushAutoRebalanceNonRack.testLackEnoughInstances(org.apache.helix.integration.rebalancer.CrushRebalancers.TestCrushAutoRebalanceNonRack)
Run 1: PASS
Run 2: TestCrushAutoRebalanceNonRack.testLackEnoughInstances:250 » ZkClient Failed to...
Tests run: 1086, Failures: 1, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
Rerun
Results :
Tests run: 8, Failures: 0, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
Helix-rest:
Results :
Tests run: 99, Failures: 0, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 37.005 s
[INFO] Finished at: 2020-03-10T11:16:28-07:00
[INFO] ------------------------------------------------------------------------
Commits
Documentation (Optional)
(Link the GitHub wiki you added)
Code Quality
(helix-style-intellij.xml if IntelliJ IDE is used)