diff --git a/apm-dist/pom.xml b/apm-dist/pom.xml
index e7d4c611b56c..8d0cd96d79cd 100644
--- a/apm-dist/pom.xml
+++ b/apm-dist/pom.xml
@@ -34,6 +34,17 @@
true
+
+
+
+ org.apache.skywalking
+ oap-server-bom
+ ${project.version}
+ import
+ pom
+
+
+
org.apache.skywalking
diff --git a/dist-material/release-docs/LICENSE b/dist-material/release-docs/LICENSE
index 8d11ad110410..efce54ed310b 100644
--- a/dist-material/release-docs/LICENSE
+++ b/dist-material/release-docs/LICENSE
@@ -212,14 +212,14 @@ The text of each license is the standard Apache 2.0 license.
https://mvnrepository.com/artifact/build.buf.protoc-gen-validate/protoc-gen-validate/0.6.13 Apache-2.0
https://mvnrepository.com/artifact/com.aayushatharva.brotli4j/brotli4j/1.15.0 Apache-2.0
https://mvnrepository.com/artifact/com.aayushatharva.brotli4j/service/1.15.0 Apache-2.0
- https://mvnrepository.com/artifact/com.alibaba.nacos/nacos-api/1.4.2 Apache-2.0
- https://mvnrepository.com/artifact/com.alibaba.nacos/nacos-client/1.4.2 Apache-2.0
- https://mvnrepository.com/artifact/com.alibaba.nacos/nacos-common/1.4.2 Apache-2.0
+ https://mvnrepository.com/artifact/com.alibaba.nacos/nacos-auth-plugin/2.3.2 Apache-2.0
+ https://mvnrepository.com/artifact/com.alibaba.nacos/nacos-client/2.3.2 Apache-2.0
+ https://mvnrepository.com/artifact/com.alibaba.nacos/nacos-encryption-plugin/2.3.2 Apache-2.0
https://mvnrepository.com/artifact/com.ctrip.framework.apollo/apollo-client/1.8.0 Apache-2.0
https://mvnrepository.com/artifact/com.ctrip.framework.apollo/apollo-core/1.8.0 Apache-2.0
- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-annotations/2.16.1 Apache-2.0
- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core/2.16.1 Apache-2.0
- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind/2.16.1 Apache-2.0
+ https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-annotations/2.16.0 Apache-2.0
+ https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core/2.16.0 Apache-2.0
+ https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind/2.16.0 Apache-2.0
https://mvnrepository.com/artifact/com.fasterxml.jackson.dataformat/jackson-dataformat-yaml/2.15.2 Apache-2.0
https://mvnrepository.com/artifact/com.fasterxml.jackson.datatype/jackson-datatype-guava/2.12.0 Apache-2.0
https://mvnrepository.com/artifact/com.fasterxml.jackson.datatype/jackson-datatype-jdk8/2.16.1 Apache-2.0
@@ -243,15 +243,14 @@ The text of each license is the standard Apache 2.0 license.
https://mvnrepository.com/artifact/com.linecorp.armeria/armeria-graphql-protocol/1.27.3 Apache-2.0
https://mvnrepository.com/artifact/com.linecorp.armeria/armeria-protobuf/1.27.3 Apache-2.0
https://mvnrepository.com/artifact/com.orbitz.consul/consul-client/1.5.3 Apache-2.0
- https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp/4.9.0 Apache-2.0
- https://mvnrepository.com/artifact/com.squareup.okio/okio/2.8.0 Apache-2.0
+ https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp/3.14.9 Apache-2.0
+ https://mvnrepository.com/artifact/com.squareup.okio/okio/1.17.2 Apache-2.0
https://mvnrepository.com/artifact/com.squareup.retrofit2/converter-jackson/2.9.0 Apache-2.0
https://mvnrepository.com/artifact/com.squareup.retrofit2/retrofit/2.9.0 Apache-2.0
https://mvnrepository.com/artifact/com.zaxxer/HikariCP/3.1.0 Apache-2.0
https://mvnrepository.com/artifact/commons-beanutils/commons-beanutils/1.9.4 Apache-2.0
https://mvnrepository.com/artifact/commons-codec/commons-codec/1.11 Apache-2.0
https://mvnrepository.com/artifact/commons-io/commons-io/2.7 Apache-2.0
- https://mvnrepository.com/artifact/commons-logging/commons-logging/1.2 Apache-2.0
https://mvnrepository.com/artifact/commons-net/commons-net/3.9.0 Apache-2.0
https://mvnrepository.com/artifact/commons-validator/commons-validator/1.7 Apache-2.0
https://npmjs.com/package/d3-flame-graph/v/4.1.3 4.1.3 Apache-2.0
@@ -303,29 +302,27 @@ The text of each license is the standard Apache 2.0 license.
https://mvnrepository.com/artifact/io.micrometer/micrometer-observation/1.12.2 Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-buffer/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-codec/4.1.108.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-codec-dns/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-codec-haproxy/4.1.106.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-codec-dns/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-codec-haproxy/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-codec-http/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-codec-http2/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-codec-socks/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-common/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-handler/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-handler-proxy/4.1.108.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-resolver/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-resolver-dns/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-resolver-dns-classes-macos/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-resolver-dns-native-macos/4.1.106.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-resolver/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-resolver-dns/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-resolver-dns-classes-macos/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-resolver-dns-native-macos/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.netty/netty-tcnative-boringssl-static/2.0.52.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-tcnative-boringssl-static/2.0.61.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-tcnative-classes/2.0.61.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-classes-epoll/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-classes-kqueue/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-native-epoll/4.1.45.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-native-epoll/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-native-kqueue/4.1.106.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-native-unix-common/4.1.100.Final Apache-2.0
- https://mvnrepository.com/artifact/io.netty/netty-transport-native-unix-common/4.1.106.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-tcnative-boringssl-static/2.0.65.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-tcnative-classes/2.0.65.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-transport/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-transport-classes-epoll/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-transport-classes-kqueue/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-transport-native-epoll/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-transport-native-kqueue/4.1.108.Final Apache-2.0
+ https://mvnrepository.com/artifact/io.netty/netty-transport-native-unix-common/4.1.108.Final Apache-2.0
https://mvnrepository.com/artifact/io.perfmark/perfmark-api/0.26.0 Apache-2.0
https://mvnrepository.com/artifact/io.prometheus/simpleclient/0.6.0 Apache-2.0
https://mvnrepository.com/artifact/io.prometheus/simpleclient_common/0.6.0 Apache-2.0
@@ -337,15 +334,15 @@ The text of each license is the standard Apache 2.0 license.
https://mvnrepository.com/artifact/javax.inject/javax.inject/1 Apache-2.0
https://mvnrepository.com/artifact/joda-time/joda-time/2.10.5 Apache-2.0
https://mvnrepository.com/artifact/net.jodah/failsafe/2.4.4 Apache-2.0
- https://mvnrepository.com/artifact/org.apache.commons/commons-lang3/3.11 Apache-2.0
+ https://mvnrepository.com/artifact/org.apache.commons/commons-lang3/3.12.0 Apache-2.0
https://mvnrepository.com/artifact/org.apache.commons/commons-text/1.4 Apache-2.0
https://mvnrepository.com/artifact/org.apache.curator/curator-client/4.3.0 Apache-2.0
https://mvnrepository.com/artifact/org.apache.curator/curator-framework/4.3.0 Apache-2.0
https://mvnrepository.com/artifact/org.apache.curator/curator-recipes/4.3.0 Apache-2.0
https://mvnrepository.com/artifact/org.apache.curator/curator-x-discovery/4.3.0 Apache-2.0
https://mvnrepository.com/artifact/org.apache.groovy/groovy/4.0.15 Apache-2.0
- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpasyncclient/4.1.3 Apache-2.0
- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient/4.5.3 Apache-2.0
+ https://mvnrepository.com/artifact/org.apache.httpcomponents/httpasyncclient/4.1.5 Apache-2.0
+ https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient/4.5.13 Apache-2.0
https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore/4.4.13 Apache-2.0
https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore-nio/4.4.13 Apache-2.0
https://mvnrepository.com/artifact/org.apache.kafka/kafka-clients/3.4.0 Apache-2.0
diff --git a/docs/en/changes/changes.md b/docs/en/changes/changes.md
index a89929356214..db9ac07b0c95 100644
--- a/docs/en/changes/changes.md
+++ b/docs/en/changes/changes.md
@@ -19,6 +19,7 @@
* Add Python as a supported language for Pulsar.
* Make more proper histogram buckets for the `persistence_timer_bulk_prepare_latency`,
`persistence_timer_bulk_execute_latency` and `persistence_timer_bulk_all_latency` metrics in PersistenceTimer.
+* [Break Change] Update Nacos version to 2.3.2. Nacos 1.x server can't serve as cluster coordinator and configuration server.
#### UI
diff --git a/docs/en/setup/backend/backend-cluster.md b/docs/en/setup/backend/backend-cluster.md
index b26416ae10ba..190cf1122b6b 100644
--- a/docs/en/setup/backend/backend-cluster.md
+++ b/docs/en/setup/backend/backend-cluster.md
@@ -181,6 +181,8 @@ The following settings are provided to set the host and port manually, based on
Set the **cluster/selector** to **nacos** in the yml to enable it.
+Nacos 2.x is required.
+
```yaml
cluster:
selector: ${SW_CLUSTER:nacos}
diff --git a/docs/en/setup/backend/dynamic-config-nacos.md b/docs/en/setup/backend/dynamic-config-nacos.md
index 90a846180920..4d33c7ab701f 100755
--- a/docs/en/setup/backend/dynamic-config-nacos.md
+++ b/docs/en/setup/backend/dynamic-config-nacos.md
@@ -1,6 +1,8 @@
# Dynamic Configuration Nacos Implementation
-[Nacos](https://github.com/alibaba/nacos) is also supported as a Dynamic Configuration Center (DCC). To use it, please configure it as follows:
+[Nacos](https://github.com/alibaba/nacos) 2.x is also supported as a Dynamic Configuration Center (DCC).
+
+To use it, please configure it as follows:
```yaml
configuration:
diff --git a/oap-server-bom/pom.xml b/oap-server-bom/pom.xml
index f68c18a0ddff..4076469305dd 100644
--- a/oap-server-bom/pom.xml
+++ b/oap-server-bom/pom.xml
@@ -54,7 +54,7 @@
2.16.0
0.6.0
1.8.0
- 1.4.2
+ 2.3.2
4.3.0
2.12.0
2.18.0
@@ -71,6 +71,7 @@
1.27.3
3.0.0
4.4.13
+ 4.1.5
1.21
0.6.0
3.4.0
@@ -518,6 +519,12 @@
${httpclient.version}
+
+ org.apache.httpcomponents
+ httpasyncclient
+ ${httpasyncclient.version}
+
+
com.google.flatbuffers
flatbuffers-java
diff --git a/oap-server/server-cluster-plugin/cluster-nacos-plugin/pom.xml b/oap-server/server-cluster-plugin/cluster-nacos-plugin/pom.xml
index 1f5661004960..6d6294fe2324 100644
--- a/oap-server/server-cluster-plugin/cluster-nacos-plugin/pom.xml
+++ b/oap-server/server-cluster-plugin/cluster-nacos-plugin/pom.xml
@@ -35,32 +35,6 @@
com.alibaba.nacos
nacos-client
-
-
- org.slf4j
- slf4j-api
-
-
- org.apache.logging.log4j
- log4j-core
-
-
- org.apache.logging.log4j
- log4j-slf4j-impl
-
-
- ch.qos.logback
- logback-classic
-
-
- ch.qos.logback
- logback-core
-
-
- net.jcip
- jcip-annotations
-
-
diff --git a/oap-server/server-cluster-plugin/cluster-nacos-plugin/src/test/java/org/apache/skywalking/oap/server/cluster/plugin/nacos/ClusterModuleNacosProviderFunctionalIT.java b/oap-server/server-cluster-plugin/cluster-nacos-plugin/src/test/java/org/apache/skywalking/oap/server/cluster/plugin/nacos/ClusterModuleNacosProviderFunctionalIT.java
index 0c82fae73012..322d87de3e62 100644
--- a/oap-server/server-cluster-plugin/cluster-nacos-plugin/src/test/java/org/apache/skywalking/oap/server/cluster/plugin/nacos/ClusterModuleNacosProviderFunctionalIT.java
+++ b/oap-server/server-cluster-plugin/cluster-nacos-plugin/src/test/java/org/apache/skywalking/oap/server/cluster/plugin/nacos/ClusterModuleNacosProviderFunctionalIT.java
@@ -19,6 +19,9 @@
package org.apache.skywalking.oap.server.cluster.plugin.nacos;
import com.alibaba.nacos.api.naming.NamingService;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
import lombok.Getter;
import org.apache.skywalking.oap.server.core.cluster.ClusterCoordinator;
import org.apache.skywalking.oap.server.core.cluster.ClusterNodesQuery;
@@ -33,6 +36,7 @@
import org.apache.skywalking.oap.server.telemetry.api.MetricsCreator;
import org.apache.skywalking.oap.server.telemetry.none.MetricsCreatorNoop;
import org.apache.skywalking.oap.server.telemetry.none.NoneTelemetryProvider;
+import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
@@ -46,10 +50,6 @@
import org.testcontainers.junit.jupiter.Testcontainers;
import org.testcontainers.utility.DockerImageName;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertFalse;
import static org.junit.jupiter.api.Assertions.assertTrue;
@@ -58,17 +58,16 @@
@ExtendWith(MockitoExtension.class)
public class ClusterModuleNacosProviderFunctionalIT {
- private String nacosAddress;
- private final String username = "nacos";
- private final String password = "nacos";
-
@Container
public final GenericContainer> container =
- new GenericContainer<>(DockerImageName.parse("nacos/nacos-server:1.4.2"))
+ new GenericContainer<>(DockerImageName.parse("nacos/nacos-server:v2.3.2-slim"))
.waitingFor(Wait.forLogMessage(".*Nacos started successfully.*", 1))
.withEnv(Collections.singletonMap("MODE", "standalone"))
- .withExposedPorts(8848);
-
+ .withLogConsumer(outputFrame -> System.out.print(outputFrame.getUtf8String()))
+ .withExposedPorts(8848, 9848);
+ private final String username = "nacos";
+ private final String password = "nacos";
+ private String nacosAddress;
@Mock
private ModuleManager moduleManager;
@Mock
@@ -82,6 +81,13 @@ public void before() {
Whitebox.setInternalState(telemetryModule, "loadedProvider", telemetryProvider);
Mockito.when(moduleManager.find(TelemetryModule.NAME)).thenReturn(telemetryModule);
nacosAddress = container.getHost() + ":" + container.getMappedPort(8848);
+ Integer nacosPortOffset = container.getMappedPort(9848) - container.getMappedPort(8848);
+ System.setProperty("nacos.server.grpc.port.offset", nacosPortOffset.toString());
+ }
+
+ @AfterEach
+ public void after() {
+ System.clearProperty("nacos.server.grpc.port.offset");
}
@Test
diff --git a/oap-server/server-configuration/configuration-nacos/src/test/java/org/apache/skywalking/oap/server/configuration/nacos/NacosConfigurationIT.java b/oap-server/server-configuration/configuration-nacos/src/test/java/org/apache/skywalking/oap/server/configuration/nacos/NacosConfigurationIT.java
index 9f65b03a5e32..718a70475e6f 100644
--- a/oap-server/server-configuration/configuration-nacos/src/test/java/org/apache/skywalking/oap/server/configuration/nacos/NacosConfigurationIT.java
+++ b/oap-server/server-configuration/configuration-nacos/src/test/java/org/apache/skywalking/oap/server/configuration/nacos/NacosConfigurationIT.java
@@ -21,12 +21,18 @@
import com.alibaba.nacos.api.NacosFactory;
import com.alibaba.nacos.api.config.ConfigService;
import com.alibaba.nacos.api.exception.NacosException;
+import java.io.FileNotFoundException;
+import java.io.Reader;
+import java.util.Collections;
+import java.util.Map;
+import java.util.Properties;
import lombok.extern.slf4j.Slf4j;
import org.apache.skywalking.oap.server.library.module.ApplicationConfiguration;
import org.apache.skywalking.oap.server.library.module.ModuleManager;
import org.apache.skywalking.oap.server.library.util.CollectionUtils;
import org.apache.skywalking.oap.server.library.util.PropertyPlaceholderHelper;
import org.apache.skywalking.oap.server.library.util.ResourceUtils;
+import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Timeout;
@@ -37,12 +43,6 @@
import org.testcontainers.utility.DockerImageName;
import org.yaml.snakeyaml.Yaml;
-import java.io.FileNotFoundException;
-import java.io.Reader;
-import java.util.Collections;
-import java.util.Map;
-import java.util.Properties;
-
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertNotNull;
import static org.junit.jupiter.api.Assertions.assertNull;
@@ -51,16 +51,14 @@
@Slf4j
@Testcontainers
public class NacosConfigurationIT {
- private final Yaml yaml = new Yaml();
-
- private NacosConfigurationTestProvider provider;
-
@Container
public final GenericContainer> container =
- new GenericContainer<>(DockerImageName.parse("nacos/nacos-server:1.4.2"))
+ new GenericContainer<>(DockerImageName.parse("nacos/nacos-server:v2.3.2-slim"))
.waitingFor(Wait.forLogMessage(".*Nacos started successfully.*", 1))
.withEnv(Collections.singletonMap("MODE", "standalone"))
- .withExposedPorts(8848);
+ .withExposedPorts(8848, 9848);
+ private final Yaml yaml = new Yaml();
+ private NacosConfigurationTestProvider provider;
@BeforeEach
public void setUp() throws Exception {
@@ -76,6 +74,13 @@ public void setUp() throws Exception {
provider = (NacosConfigurationTestProvider) moduleManager.find(NacosConfigurationTestModule.NAME).provider();
assertNotNull(provider);
+ Integer nacosPortOffset = container.getMappedPort(9848) - container.getMappedPort(8848);
+ System.setProperty("nacos.server.grpc.port.offset", nacosPortOffset.toString());
+ }
+
+ @AfterEach
+ public void after() {
+ System.clearProperty("nacos.server.grpc.port.offset");
}
@SuppressWarnings("StatementWithEmptyBody")
@@ -122,28 +127,38 @@ public void shouldReadUpdatedGroup() throws NacosException {
assertTrue(configService.publishConfig("test-module.default.testKeyGroup", "skywalking", "item1\n item2"));
assertTrue(configService.publishConfig("item1", "skywalking", "100"));
assertTrue(configService.publishConfig("item2", "skywalking", "200"));
- for (String v = provider.groupWatcher.groupItems().get("item1"); v == null; v = provider.groupWatcher.groupItems().get("item1")) {
+ for (String v = provider.groupWatcher.groupItems()
+ .get("item1"); v == null; v = provider.groupWatcher.groupItems()
+ .get("item1")) {
}
- for (String v = provider.groupWatcher.groupItems().get("item2"); v == null; v = provider.groupWatcher.groupItems().get("item2")) {
+ for (String v = provider.groupWatcher.groupItems()
+ .get("item2"); v == null; v = provider.groupWatcher.groupItems()
+ .get("item2")) {
}
assertEquals("100", provider.groupWatcher.groupItems().get("item1"));
assertEquals("200", provider.groupWatcher.groupItems().get("item2"));
//test remove item1
assertTrue(configService.removeConfig("item1", "skywalking"));
- for (String v = provider.groupWatcher.groupItems().get("item1"); v != null; v = provider.groupWatcher.groupItems().get("item1")) {
+ for (String v = provider.groupWatcher.groupItems()
+ .get("item1"); v != null; v = provider.groupWatcher.groupItems()
+ .get("item1")) {
}
assertNull(provider.groupWatcher.groupItems().get("item1"));
//test modify item1
assertTrue(configService.publishConfig("item1", "skywalking", "300"));
- for (String v = provider.groupWatcher.groupItems().get("item1"); v == null; v = provider.groupWatcher.groupItems().get("item1")) {
+ for (String v = provider.groupWatcher.groupItems()
+ .get("item1"); v == null; v = provider.groupWatcher.groupItems()
+ .get("item1")) {
}
assertEquals("300", provider.groupWatcher.groupItems().get("item1"));
//test remove group key
assertTrue(configService.removeConfig("test-module.default.testKeyGroup", "skywalking"));
- for (String v = provider.groupWatcher.groupItems().get("item2"); v != null; v = provider.groupWatcher.groupItems().get("item2")) {
+ for (String v = provider.groupWatcher.groupItems()
+ .get("item2"); v != null; v = provider.groupWatcher.groupItems()
+ .get("item2")) {
}
assertNull(provider.groupWatcher.groupItems().get("item2"));
//chean
@@ -158,13 +173,15 @@ private void loadConfig(ApplicationConfiguration configuration) throws FileNotFo
if (CollectionUtils.isNotEmpty(moduleConfig)) {
moduleConfig.forEach((moduleName, providerConfig) -> {
if (providerConfig.size() > 0) {
- ApplicationConfiguration.ModuleConfiguration moduleConfiguration = configuration.addModule(moduleName);
+ ApplicationConfiguration.ModuleConfiguration moduleConfiguration = configuration.addModule(
+ moduleName);
providerConfig.forEach((name, propertiesConfig) -> {
Properties properties = new Properties();
if (propertiesConfig != null) {
propertiesConfig.forEach((key, value) -> {
properties.put(key, value);
- final Object replaceValue = yaml.load(PropertyPlaceholderHelper.INSTANCE.replacePlaceholders(value + "", properties));
+ final Object replaceValue = yaml.load(
+ PropertyPlaceholderHelper.INSTANCE.replacePlaceholders(value + "", properties));
if (replaceValue != null) {
properties.replace(key, replaceValue);
}
diff --git a/oap-server/server-starter/src/main/resources/application.yml b/oap-server/server-starter/src/main/resources/application.yml
index 9e391d49216e..c647418c462b 100644
--- a/oap-server/server-starter/src/main/resources/application.yml
+++ b/oap-server/server-starter/src/main/resources/application.yml
@@ -54,7 +54,7 @@ cluster:
nacos:
serviceName: ${SW_SERVICE_NAME:"SkyWalking_OAP_Cluster"}
hostPort: ${SW_CLUSTER_NACOS_HOST_PORT:localhost:8848}
- # Nacos Configuration namespace
+ # Nacos Naming namespace
namespace: ${SW_CLUSTER_NACOS_NAMESPACE:"public"}
# Nacos auth username
username: ${SW_CLUSTER_NACOS_USERNAME:""}