diff --git a/cachecloud-open-client/cachecloud-jedis/src/main/java/redis/clients/util/ClusterNodeInformationParser.java b/cachecloud-open-client/cachecloud-jedis/src/main/java/redis/clients/util/ClusterNodeInformationParser.java index 8352dc3c..5eab97c9 100644 --- a/cachecloud-open-client/cachecloud-jedis/src/main/java/redis/clients/util/ClusterNodeInformationParser.java +++ b/cachecloud-open-client/cachecloud-jedis/src/main/java/redis/clients/util/ClusterNodeInformationParser.java @@ -34,6 +34,11 @@ private String[] extractSlotParts(String[] nodeInfoPartArray) { public HostAndPort getHostAndPortFromNodeLine(String[] nodeInfoPartArray, HostAndPort current) { String stringHostAndPort = nodeInfoPartArray[HOST_AND_PORT_INDEX]; + int index = stringHostAndPort.indexOf("@"); + if (index != -1 ){ + stringHostAndPort = stringHostAndPort.substring(0, index); + } + String[] arrayHostAndPort = stringHostAndPort.split(":"); return new HostAndPort(arrayHostAndPort[0].isEmpty() ? current.getHost() : arrayHostAndPort[0], arrayHostAndPort[1].isEmpty() ? current.getPort() : Integer.valueOf(arrayHostAndPort[1]));