File tree Expand file tree Collapse file tree 2 files changed +0
-17
lines changed Expand file tree Collapse file tree 2 files changed +0
-17
lines changed Original file line number Diff line number Diff line change @@ -46,19 +46,6 @@ type Balancer struct {
4646 onApplyDiscoveredEndpoints []func (ctx context.Context , endpoints []endpoint.Info )
4747}
4848
49- func (b * Balancer ) HasNode (id uint32 ) bool {
50- if b .config .SingleConn {
51- return true
52- }
53- b .mu .RLock ()
54- defer b .mu .RUnlock ()
55- if _ , has := b .connectionsState .connByNodeID [id ]; has {
56- return true
57- }
58-
59- return false
60- }
61-
6249func (b * Balancer ) OnUpdate (onApplyDiscoveredEndpoints func (ctx context.Context , endpoints []endpoint.Info )) {
6350 b .mu .WithLock (func () {
6451 b .onApplyDiscoveredEndpoints = append (b .onApplyDiscoveredEndpoints , onApplyDiscoveredEndpoints )
Original file line number Diff line number Diff line change @@ -138,10 +138,6 @@ type balancerStub struct {
138138 ) (grpc.ClientStream , error )
139139}
140140
141- func (b * balancerStub ) HasNode (id uint32 ) bool {
142- return true
143- }
144-
145141func (b * balancerStub ) Invoke (
146142 ctx context.Context ,
147143 method string ,
You can’t perform that action at this time.
0 commit comments