mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-10-12 22:15:02 +00:00
fix[net]: 优雅关闭服务器的时候zookeeper的空指针异常
This commit is contained in:
1 parent
037eeaecb5
commit
20d9f45679
1 file changed
+3
@@ -573,6 +573,9 @@ public class ZookeeperRegistry implements IRegistry {
|
||||
|
||||
@Override
|
||||
public void shutdown() {
|
||||
if (curator == null) {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
if (curator.getState() == CuratorFrameworkState.STARTED) {
|
||||
// 删除服务提供者的临时节点
|
||||
|
||||
Reference in new issue
Block a user