-
Notifications
You must be signed in to change notification settings - Fork 4.5k
xds/priority: bug fix and minor behavior change #5417
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
Conversation
- Bug: push config updates to all child policies, not just the active one. - Process all child picker updates before determining active priority.
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.
First PR done! I'm super proud of my comments :D.
// an update of the aggregated picker to the parent. Cleared after all | ||
// sub-balancers have finished UpdateClientConnState, after which | ||
// syncPriority is called manually. | ||
inhibitChildUpdates bool |
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.
Nit: I don't like this name. We are inhibiting the child picker updates, but we are inhibiting the calculation/synchronization of the priority, which determines what child picker update to send back. Maybe inhibitSyncPriority?
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.
inhibitPickerUpdates
?
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.
Yeah sure, even though syncPriority calls aren't exactly 1:1 with a picker update, you're still inhibiting all of the possible picker updates, even though that's only a fraction of the time syncPriority is called.
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.
syncPriority
is the only thing that pushes a picker update to the parent policy, which is how I was thinking of this (and how the functionality was debated/designed cross-language).
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! Now I need to go watch the Warriors win a championship.
} | ||
|
||
// Two new subconns are created by the previous update; one by p0 and one | ||
// by p1. They don't happen concurrently, but they could happen in any |
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.
Nondeterministic map iterations :0.
// an update of the aggregated picker to the parent. Cleared after all | ||
// sub-balancers have finished UpdateClientConnState, after which | ||
// syncPriority is called manually. | ||
inhibitChildUpdates bool |
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.
Yeah sure, even though syncPriority calls aren't exactly 1:1 with a picker update, you're still inhibiting all of the possible picker updates, even though that's only a fraction of the time syncPriority is called.
#5211
Logic changes are all in
.../balancer/priority/*.go
; the other changes are tests that are too dependent on the priority balancer's behavior (not correctness related; just not allowing for the possibility of duplicate picker updates).RELEASE NOTES: