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
xds: add LRS balancing policy #3799
Conversation
select { | ||
case <-time.After(time.Second): | ||
return nil, fmt.Errorf("timeout") | ||
case a := <-xdsC.loadReportCh: |
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.
Why not make this loadReportCh
of type testutils.Channel
which provides a timed receive operation?
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.
Because it cannot import testutils
..
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.
Hmm .... I thought it only cannot import the fakeclient
package which imports lrs
. But testutils
package shouldn't have a dependency on lrs
.
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.
Yes.
It is because xds-client takes lrs.Store as an input. It should be refactored to own the lrs.Store. And after that, this dependency will be gone.
LB config as in https://github.com/grpc/grpc-proto/blob/master/grpc/service_config/service_config.proto#L292