作者 crossoverJie

:bug: Fixing a bug.优化 Zookeeper

@@ -41,7 +41,7 @@ public class RegistryZK implements Runnable { @@ -41,7 +41,7 @@ public class RegistryZK implements Runnable {
41 //是否要将自己注册到 ZK 41 //是否要将自己注册到 ZK
42 if (appConfiguration.isZkSwitch()){ 42 if (appConfiguration.isZkSwitch()){
43 String path = appConfiguration.getZkRoot() + "/ip-" + ip + ":" + cimServerPort + ":" + httpPort; 43 String path = appConfiguration.getZkRoot() + "/ip-" + ip + ":" + cimServerPort + ":" + httpPort;
44 - zKit.createNode(path, path); 44 + zKit.createNode(path);
45 logger.info("注册 zookeeper 成功,msg=[{}]", path); 45 logger.info("注册 zookeeper 成功,msg=[{}]", path);
46 } 46 }
47 47
@@ -43,10 +43,9 @@ public class ZKit { @@ -43,10 +43,9 @@ public class ZKit {
43 * 写入指定节点 临时目录 43 * 写入指定节点 临时目录
44 * 44 *
45 * @param path 45 * @param path
46 - * @param value  
47 */ 46 */
48 - public void createNode(String path, String value) {  
49 - zkClient.createEphemeral(path, value); 47 + public void createNode(String path) {
  48 + zkClient.createEphemeral(path);
50 } 49 }
51 50
52 } 51 }