mirror of https://github.com/grpc/grpc-go.git
xds: give up pool lock before closing xdsclient channel, preventing deadlocks with nested xds
This commit is contained in:
parent
3d0cb79a78
commit
91c08f46d6
|
|
@ -227,7 +227,6 @@ func (p *Pool) clientRefCountedClose(name string) {
|
|||
}
|
||||
delete(p.clients, name)
|
||||
|
||||
client.Close()
|
||||
for _, s := range client.bootstrapConfig.XDSServers() {
|
||||
for _, f := range s.Cleanups() {
|
||||
f()
|
||||
|
|
@ -242,6 +241,8 @@ func (p *Pool) clientRefCountedClose(name string) {
|
|||
}
|
||||
p.mu.Unlock()
|
||||
|
||||
client.Close()
|
||||
|
||||
xdsClientImplCloseHook(name)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue