You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2020/07/01 05:02:30 UTC
[dubbo] branch master updated: Do not clear all configurator
instances when override is empty (#6395)
This is an automated email from the ASF dual-hosted git repository.
liujun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/dubbo.git
The following commit(s) were added to refs/heads/master by this push:
new 1c407de Do not clear all configurator instances when override is empty (#6395)
1c407de is described below
commit 1c407deb0044cbae39e242a2bda2b691d3f722a0
Author: Joe Zou <jo...@apache.org>
AuthorDate: Wed Jul 1 13:02:13 2020 +0800
Do not clear all configurator instances when override is empty (#6395)
---
.../src/main/java/org/apache/dubbo/rpc/cluster/Configurator.java | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/Configurator.java b/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/Configurator.java
index 24e5683..436f0dc 100644
--- a/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/Configurator.java
+++ b/dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/Configurator.java
@@ -86,8 +86,7 @@ public interface Configurator extends Comparable<Configurator> {
Map<String, String> override = new HashMap<>(url.getParameters());
//The anyhost parameter of override may be added automatically, it can't change the judgement of changing url
override.remove(ANYHOST_KEY);
- if (override.size() == 0) {
- configurators.clear();
+ if (CollectionUtils.isEmptyMap(override)) {
continue;
}
configurators.add(configuratorFactory.getConfigurator(url));