提交 32a21a1e 编写于 作者: W william.liangf

修改zookeeper会话过期重连

git-svn-id: http://code.alibabatech.com/svn/dubbo/trunk@218 1a56cb94-b969-4eaa-88fa-be21384802f2
上级 c900d4c2
......@@ -60,20 +60,16 @@ public class ZookeeperRegistry extends FailbackRegistry {
public ZookeeperRegistry(URL url) {
super(url);
try {
initZookeeper(url);
this.auth = url.getUsername() != null && url.getUsername().length() > 0
&& url.getPassword() != null && url.getPassword().length() > 0;
String group = url.getParameter(Constants.GROUP_KEY);
if (group != null && group.length() > 0) {
group = SEPARATOR + group;
this.root = group;
} else {
this.root = "";
}
} catch (Exception e) {
throw new IllegalStateException(e.getMessage(), e);
this.auth = url.getUsername() != null && url.getUsername().length() > 0
&& url.getPassword() != null && url.getPassword().length() > 0;
String group = url.getParameter(Constants.GROUP_KEY);
if (group != null && group.length() > 0) {
group = SEPARATOR + group;
this.root = group;
} else {
this.root = "";
}
initZookeeper(url);
}
@Override
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册