You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// For compatibility purpose, use registry as the default config center if the registry protocol is zookeeper and there's no config center specified explicitly.
157
+
useRegistryForConfigIfNecessary();
158
+
}
159
+
160
+
/**
161
+
* For compatibility purpose, use registry as the default config center if the registry protocol is zookeeper and
Copy file name to clipboardexpand all lines: dubbo-configcenter/dubbo-configcenter-api/src/main/java/org/apache/dubbo/configcenter/ConfigurationListener.java
-5
Original file line number
Diff line number
Diff line change
@@ -16,8 +16,6 @@
16
16
*/
17
17
packageorg.apache.dubbo.configcenter;
18
18
19
-
importorg.apache.dubbo.common.URL;
20
-
21
19
/**
22
20
* Config listener, will get notified when the config it listens on changes.
23
21
*/
@@ -30,7 +28,4 @@ public interface ConfigurationListener {
Copy file name to clipboardexpand all lines: dubbo-configcenter/dubbo-configcenter-apollo/src/main/java/org/apache/dubbo/configcenter/support/apollo/ApolloDynamicConfiguration.java
if (dubboConfig.getSourceType() != ConfigSourceType.REMOTE) {
77
78
if (check) {
78
-
thrownewIllegalStateException("Failed to connect to ConfigCenter, the ConfigCenter is Apollo, the address is: " + (StringUtils.isNotEmpty(configAddr) ? configAddr : configEnv));
79
+
thrownewIllegalStateException("Failed to connect to config center, the config center is Apollo, " +
80
+
"the address is: " + (StringUtils.isNotEmpty(configAddr) ? configAddr : configEnv));
79
81
} else {
80
-
logger.warn("Failed to connect to ConfigCenter, the ConfigCenter is Apollo, " +
82
+
logger.warn("Failed to connect to config center, the config center is Apollo, " +
81
83
"the address is: " + (StringUtils.isNotEmpty(configAddr) ? configAddr : configEnv) +
82
-
". will use the local cache value instead before finally connected.");
84
+
", will use the local cache value instead before eventually the connection is established.");
logger.warn("We received an empty rule for " + key + ", the current working rule is " + change.getOldValue() + ", the empty rule will not take effect.");
139
+
logger.warn("an empty rule is received for " + key + ", the current working rule is " +
140
+
change.getOldValue() + ", the empty rule will not take effect.");
160
141
return;
161
142
}
162
-
// TODO Maybe we no longer need to identify the type of change. Because there's no scenario that a callback will subscribe for both configurators and routers
143
+
// TODO Maybe we no longer need to identify the type of change. Because there's no scenario that
144
+
// a callback will subscribe for both configurators and routers
163
145
if (change.getPropertyName().endsWith(Constants.CONFIGURATORS_SUFFIX)) {
Copy file name to clipboardexpand all lines: dubbo-configcenter/dubbo-configcenter-zookeeper/src/main/java/org/apache/dubbo/configcenter/support/archaius/ArchaiusDynamicConfiguration.java
* To make the API compatible with other configuration systems, the key doesn't has group as prefix, so we should add the group prefix before try to get value.
77
-
* If being used for dubbo router rules, the key must already contains group prefix.
78
-
*
79
-
* @param key
80
-
* @param group
81
-
* @param timeout
82
-
* @return
84
+
* To make the API compatible with other configuration systems, the key doesn't has group as prefix, so we should
85
+
* add the group prefix before try to get value. If being used for dubbo router rules, the key must already
// Maybe we no longer need to identify the type of change. Because there's no scenario that a callback will subscribe for both configurators and routers
129
+
// Maybe we no longer need to identify the type of change. Because there's no scenario that a callback
130
+
// will subscribe for both configurators and routers
132
131
if (key.endsWith(Constants.CONFIGURATORS_SUFFIX)) {
133
132
type = ConfigType.CONFIGURATORS;
134
133
} else {
@@ -152,7 +151,8 @@ public void run() {
152
151
listener.process(event);
153
152
} else {
154
153
if (newValue.equals("")) {
155
-
logger.warn("We received an empty rule for " + key + ", the current working rule is unknown, the empty rule will not take effect.");
154
+
logger.warn("an empty rule is received for " + key + ", the current working rule is unknown, " +
0 commit comments