From 50c78127e038b967537fcb4f9f4c35bea7588563 Mon Sep 17 00:00:00 2001
From: "vito.he" <hxmhlt@163.com>
Date: Sun, 5 May 2019 20:18:23 +0800
Subject: [PATCH] Add:2.6.0 interface in urlmap

---
 config/support/reference_config.go | 2 +-
 config/support/service_config.go   | 2 +-
 registry/zookeeper/registry.go     | 2 --
 3 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/config/support/reference_config.go b/config/support/reference_config.go
index f835eb38a..7e4de409e 100644
--- a/config/support/reference_config.go
+++ b/config/support/reference_config.go
@@ -82,7 +82,7 @@ func (refconfig *ReferenceConfig) GetRPCService() config.RPCService {
 
 func (refconfig *ReferenceConfig) getUrlMap() url.Values {
 	urlMap := url.Values{}
-
+	urlMap.Set(constant.INTERFACE_KEY, refconfig.InterfaceName)
 	urlMap.Set(constant.TIMESTAMP_KEY, strconv.FormatInt(time.Now().Unix(), 10))
 	urlMap.Set(constant.CLUSTER_KEY, refconfig.Cluster)
 	urlMap.Set(constant.LOADBALANCE_KEY, refconfig.Loadbalance)
diff --git a/config/support/service_config.go b/config/support/service_config.go
index f6ff4a100..56b7b6d83 100644
--- a/config/support/service_config.go
+++ b/config/support/service_config.go
@@ -112,7 +112,7 @@ func (srvconfig *ServiceConfig) Implement(s config.RPCService) {
 
 func (srvconfig *ServiceConfig) getUrlMap() url.Values {
 	urlMap := url.Values{}
-
+	urlMap.Set(constant.INTERFACE_KEY, srvconfig.InterfaceName)
 	urlMap.Set(constant.TIMESTAMP_KEY, strconv.FormatInt(time.Now().Unix(), 10))
 	urlMap.Set(constant.CLUSTER_KEY, srvconfig.Cluster)
 	urlMap.Set(constant.LOADBALANCE_KEY, srvconfig.Loadbalance)
diff --git a/registry/zookeeper/registry.go b/registry/zookeeper/registry.go
index 11576a507..02c001307 100644
--- a/registry/zookeeper/registry.go
+++ b/registry/zookeeper/registry.go
@@ -312,7 +312,6 @@ func (r *ZkRegistry) register(c config.URL) error {
 			return jerrors.Annotatef(err, "zkclient.Create(path:%s)", dubboPath)
 		}
 		params.Add("anyhost", "true")
-		params.Add("interface", c.Service())
 
 		// dubbo java consumer鏉ュ惎鍔ㄦ壘provider url鏃讹紝鍥犱负category涓嶅尮閰嶏紝浼氭壘涓嶅埌provider锛屽鑷碿onsumer鍚姩涓嶄簡,鎵€浠ヤ娇鐢╟onsumers&providers
 		// DubboRole               = [...]string{"consumer", "", "", "provider"}
@@ -362,7 +361,6 @@ func (r *ZkRegistry) register(c config.URL) error {
 		}
 
 		params.Add("protocol", c.Protocol)
-		params.Add("interface", c.Service())
 
 		params.Add("category", (config.RoleType(config.CONSUMER)).String())
 		params.Add("dubbo", "dubbogo-consumer-"+version.Version)
-- 
GitLab