From 08e8cb9c3c5fdd70ff82cb06057e3b48ec66d62d Mon Sep 17 00:00:00 2001 From: Arjan Bal Date: Mon, 2 Sep 2024 13:51:48 +0530 Subject: [PATCH] Keep b.state and state rerported to clientconn in sync --- balancer/pickfirstleaf/pickfirstleaf.go | 1 + 1 file changed, 1 insertion(+) diff --git a/balancer/pickfirstleaf/pickfirstleaf.go b/balancer/pickfirstleaf/pickfirstleaf.go index 3b72c6d7e304..7f7b58d470f8 100644 --- a/balancer/pickfirstleaf/pickfirstleaf.go +++ b/balancer/pickfirstleaf/pickfirstleaf.go @@ -477,6 +477,7 @@ func (b *pickfirstBalancer) updateSubConnState(sd *scData, state balancer.SubCon // it's READY. See A62. // If the balancer is already in CONNECTING, no update is needed. if b.state == connectivity.Idle { + b.state = connectivity.Connecting b.cc.UpdateState(balancer.State{ ConnectivityState: connectivity.Connecting, Picker: &picker{err: balancer.ErrNoSubConnAvailable},