-
Notifications
You must be signed in to change notification settings - Fork 2.3k
[Fix Bug] Allocation and Rebalance Constraints of WeightFunction are incorrectly reset #19012
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
[Fix Bug] Allocation and Rebalance Constraints of WeightFunction are incorrectly reset #19012
Conversation
Signed-off-by: guojialiang <guojialiang.2012@bytedance.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #19012 +/- ##
============================================
+ Coverage 73.05% 73.06% +0.01%
- Complexity 70627 70639 +12
============================================
Files 5723 5723
Lines 323489 323493 +4
Branches 46851 46851
============================================
+ Hits 236311 236368 +57
+ Misses 68174 68057 -117
- Partials 19004 19068 +64 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
This PR is stalled because it has been open for 30 days with no activity. |
…ce-strategy-unset-bug
|
❌ Gradle check result for 17a9dd3: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
Signed-off-by: guojialiang <guojialiang.2012@bytedance.com>
|
❕ Gradle check result for 72ab29b: UNSTABLE Please review all flaky tests that succeeded after retry and create an issue if one does not already exist to track the flaky failure. |
kkewwei
left a comment
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, there are no major issues. There's a minor point to consider: should we add unit tests in BalancedShardsAllocatorTests, or would it be more appropriate to add them in LocalShardsBalancerTests?
...c/main/java/org/opensearch/cluster/routing/allocation/allocator/BalancedShardsAllocator.java
Outdated
Show resolved
Hide resolved
…ce-strategy-unset-bug
…incorrectly reset (opensearch-project#19012) * fix primary balance strategy unset Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * Add change log Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * refactor Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * refactor Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * refactor Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> --------- Signed-off-by: guojialiang <guojialiang.2012@bytedance.com>
…incorrectly reset (opensearch-project#19012) * fix primary balance strategy unset Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * Add change log Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * refactor Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * refactor Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> * refactor Signed-off-by: guojialiang <guojialiang.2012@bytedance.com> --------- Signed-off-by: guojialiang <guojialiang.2012@bytedance.com>
Description
This PR reproduced the issue (#[13429]) in Test
SegmentReplicationAllocationIT#testSingleIndexShardAllocation. Without this fix, the test will fail consistently.This issue was raised a year ago but has never been fixed. We also encountered the same issue in the segment replication scenario with primary shard balance enabled, and have fixed it.
Related Issues
Resolves #[13429]
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.