-
Notifications
You must be signed in to change notification settings - Fork 302
registry/rpc: use simpleBalancer instead of ClientConn.State() #1673
registry/rpc: use simpleBalancer instead of ClientConn.State() #1673
Conversation
af9b893
to
6d3a053
Compare
bdc94e8
to
fa5aa3a
Compare
log.Infof("Status of rpc service: %d, connection state: %s", status, connState) | ||
return status == pb.HealthCheckResponse_SERVING && err == nil | ||
} | ||
// NOTE: checking for readyc doesn't work as expected. |
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.
Is this part WIP ?
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 right. I need to have a deeper look into this one. Unfortunately checking the readyc doesn't work as expected. If you have a better idea, please let me know. TBH I'm just a beginner of the new API of gRPC v1.0 or etcdv3.
@dongsupark could add a bigger description about what the balancer does ? |
@hectorj2f Sure, I will split it into multiple PRs, and add more descriptions. |
6d3a053
to
f5f9223
Compare
Force-pushed it by changing the following:
And I created 2 PRs, #1676 (only vendor updates) and #1677 (relevant code), for easier reviews. |
FYI. |
Update vendor/google.golang.org/grpc to the most recent master, as of 2016-08-26.
Now that gRPC as well as other dependencies were updated, we need to update fleet.pb.go too.
4ef338e
to
ecb121a
Compare
As ClientConn.State() of gRPC has disappeared, we need to avoid using ClientConn.State(). Instead we should make use of gRPC rebalancer mechanism, just like etcdv3 is doing. To do that, introduce simpleBalancer, as a minimum structure to be used for grpc.Balancer.
20a3e96
to
3aaa1ab
Compare
I finally got some time to do nomi benchmarks again. This time, I cannot see the regression any more. When tested with etcd v3, results of master branch and this branch are nearly the same. What I saw in September was probably just because of mistake in testing. |
I can confirm that its performance is all right. |
registry/rpc: use simpleBalancer instead of ClientConn.State()
registry/rpc: use simpleBalancer instead of ClientConn.State()
registry/rpc: use simpleBalancer instead of ClientConn.State()
As
ClientConn.State()
of gRPC has disappeared, we need to avoid usingClientConn.State()
. Instead we should make use of gRPC rebalancer mechanism, just like etcdv3 is doing. To do that, introducesimpleBalancer
, as a minimum structure to be used forgrpc.Balancer
.Note that this change could be possibly invasive to the current behavior of fleet's gRPC. A careful review is needed.
/cc @hectorj2f
Fixes #1672