-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add Exit Idle to LbPolicy Trait #2332
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
base: master
Are you sure you want to change the base?
Conversation
|
||
fn exit_idle(&mut self, channel_controller: &mut dyn ChannelController) { | ||
todo!() | ||
// TODO(cjzhao): add exit idle logic once everything has been merged in |
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.
Note that the todo!
macro accepts a string that is printed when it is encountered, which might be nicer. Just todo!("implement exit_idle")
seems fine.
/// Called by policy when it needs to exit the idle state and start connecting | ||
/// to subchannels. |
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.
This is a method on the policy, so it is called by the channel when it wants the lb policy to connect.
@@ -219,6 +219,11 @@ impl<T: PartialEq + Hash + Eq + Send> LbPolicy for ChildManager<T> { | |||
fn work(&mut self, _channel_controller: &mut dyn ChannelController) { | |||
todo!(); | |||
} | |||
|
|||
fn exit_idle(&mut self, channel_controller: &mut dyn ChannelController) { |
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.
Please fix the CI error that happened for this line.
Add exit_idle to LbPolicy Trait and Child Manager.
@dfawley @easwars