-
Notifications
You must be signed in to change notification settings - Fork 229
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[apache/helix] -- Fixes #2646 Optimize WagedInstanceCapacity Calculation to improve Helix Controller Pipeline #2649
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initial comments. will do second pass later. THANKS a lot for working.
wondering if we can have some profile numbers
...x-core/src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacity.java
Outdated
Show resolved
Hide resolved
...x-core/src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacity.java
Outdated
Show resolved
Hide resolved
...src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacityManager.java
Outdated
Show resolved
Hide resolved
Yes, this is quite important. I am working on the Integ test and will share the numbers. |
Hey @desaikomal here are the results from the performance testing (CurrentStateComputationStage):
|
d6eb518
to
0d8c202
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we need to chat offline... I have few questions about this PR.
...src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacityManager.java
Outdated
Show resolved
Hide resolved
...src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacityManager.java
Outdated
Show resolved
Hide resolved
...x-core/src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacity.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good, performance number looks good. also please update the change description as events are different. once you address Junkai's comment, will review it last time. almost there.
...x-core/src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacity.java
Outdated
Show resolved
Hide resolved
...x-core/src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacity.java
Show resolved
Hide resolved
...src/main/java/org/apache/helix/controller/rebalancer/waged/WagedInstanceCapacityManager.java
Outdated
Show resolved
Hide resolved
…apacity Calculation to improve Helix Controller Pipeline
…apacity Calculation to improve Helix Controller Pipeline
0d8c202
to
6430b59
Compare
…apacity Calculation to improve Helix Controller Pipeline
helix-core/src/main/java/org/apache/helix/controller/stages/CurrentStateComputationStage.java
Show resolved
Hide resolved
helix-core/src/main/java/org/apache/helix/controller/stages/CurrentStateComputationStage.java
Outdated
Show resolved
Hide resolved
…apacity Calculation to improve Helix Controller Pipeline
…apacity Calculation to improve Helix Controller Pipeline
…t-constraint evenness scoring calculation
This PR is approved by @junkaixue and is ready to be merged. Final commit message: |
Issues
Optimize WagedInstanceCapacity Calculation to improve Helix Controller Pipeline #2646
Description
WagedInstanceCapacity data-structure is computed every time during a pipeline run and in case of large clusters, this computation takes ~80% of total time and hence, it's important to improve its performance.
In this PR, we are performing following changes:
WagedInstanceCapacityManager
class to cleanly factor-out the operations on WagedInstanceCapacity cache. It contains the condition on when the full build of cache should or shouldn't happen. With this we are skipping the full cache building in case ofTaskCurrentStateChange
,MessageChange
, andResume
events.Tests
TestWagedInstanceCapacityManager
TestWagedInstanceCapacity
TestPipelinePerformance
Changes that Break Backward Compatibility (Optional)
(Consider including all behavior changes for public methods or API. Also include these changes in merge description so that other developers are aware of these changes. This allows them to make relevant code changes in feature branches accounting for the new method/API behavior.)
Documentation (Optional)
(Link the GitHub wiki you added)
Commits
Code Quality
(helix-style-intellij.xml if IntelliJ IDE is used)