From e6f82a940e6e20d507779fad97e8d343b95736a7 Mon Sep 17 00:00:00 2001 From: Albert-Hugo Date: Sat, 20 Apr 2019 10:35:01 +0800 Subject: [PATCH] remove useless validate code --- .../main/java/com/alibaba/nacos/naming/core/Instance.java | 7 ------- 1 file changed, 7 deletions(-) diff --git a/naming/src/main/java/com/alibaba/nacos/naming/core/Instance.java b/naming/src/main/java/com/alibaba/nacos/naming/core/Instance.java index 0cec5d23c..1941959fc 100644 --- a/naming/src/main/java/com/alibaba/nacos/naming/core/Instance.java +++ b/naming/src/main/java/com/alibaba/nacos/naming/core/Instance.java @@ -297,13 +297,6 @@ public class Instance extends com.alibaba.nacos.api.naming.pojo.Instance impleme public boolean validate() { - if (getIp().contains(UtilsAndCommons.IP_PORT_SPLITER)) { - Matcher matcher = IP_PATTERN.matcher(getIp() + ":" + getPort()); - if (!matcher.matches()) { - return false; - } - } - if (getWeight() > MAX_WEIGHT_VALUE || getWeight() < MIN_WEIGHT_VALUE) { return false; }