-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[fix][broker] rackaware policy is ineffective when delete zk rack info after bkclient initialize #20944
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][broker] rackaware policy is ineffective when delete zk rack info after bkclient initialize #20944
Conversation
|
The pr had no activity for 30 days, mark with Stale label. |
e60964b to
8930c21
Compare
horizonzy
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.
LGTM.
|
/pulsarbot run-failure-checks |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #20944 +/- ##
=============================================
- Coverage 72.97% 36.80% -36.18%
+ Complexity 32157 374 -31783
=============================================
Files 1868 1698 -170
Lines 139164 130430 -8734
Branches 15314 14250 -1064
=============================================
- Hits 101555 47999 -53556
- Misses 29562 76104 +46542
+ Partials 8047 6327 -1720
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
…o after bkclient initialize (apache#20944)
…o after bkclient initialize (apache#20944)
…o after bkclient initialize (#20944)
…o after bkclient initialize (apache#20944) (cherry picked from commit d9ebaf5)
…o after bkclient initialize (apache#20944) (cherry picked from commit d9ebaf5)
…o after bkclient initialize (apache#20944)
…o after bkclient initialize (apache#20944)
…o after bkclient initialize (apache#20944) (cherry picked from commit d9ebaf5)
Motivation
#14248 fix rackaware placement policy does not take effect after delete rack configuration. But after #16825, this fix is ineffective when delete zk rack info after bkclient initialize.
The reason is "register available bookie" is after "BookieRackAffinityMapping#setConf" in bookieClient constructor. So updateRacksWithHost(racksWithHost) would throw BookieIdNotResolvedException, make "racksWithHost" become null. "racksWithHost" is updated until "watchAvailableBookies()" listener is trigger.
I add some log of unittest testRackUpdate() to show the order of bookieClient constructor:
Modifications
Verifying this change
Does this pull request potentially affect one of the following parts:
If the box was checked, please highlight the changes
Documentation
docdoc-requireddoc-not-neededdoc-completeMatching PR in forked repository
PR in forked repository: TakaHiR07#12