Skip to content
Snippets Groups Projects
Commit 2e534519 authored by Ming Deng's avatar Ming Deng
Browse files

Fix UT

parent eaee80e4
No related branches found
No related tags found
No related merge requests found
......@@ -109,7 +109,13 @@ func (l *RegistryConfigurationListener) Next() (*registry.ServiceEvent, error) {
}
}
func (l *RegistryConfigurationListener) Close() {
l.client.Close()
if l.registry.IsAvailable() {
/**
* if the registry is not available, it means that the registry has been destroy
* so we don't need to call Done(), or it will cause the negative count panic for registry.wg
*/
l.registry.wg.Done()
}
}
func (l *RegistryConfigurationListener) valid() bool {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment