diff --git a/dubbo-cluster/pom.xml b/dubbo-cluster/pom.xml
index 093999874143..91a7b40f69e4 100644
--- a/dubbo-cluster/pom.xml
+++ b/dubbo-cluster/pom.xml
@@ -92,11 +92,6 @@
micrometer-tracing-integration-test
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/support/FailbackClusterInvokerTest.java b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/support/FailbackClusterInvokerTest.java
index 413cc9615d08..63dbe8936846 100644
--- a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/support/FailbackClusterInvokerTest.java
+++ b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/support/FailbackClusterInvokerTest.java
@@ -18,6 +18,7 @@
import org.apache.dubbo.common.URL;
import org.apache.dubbo.common.constants.CommonConstants;
+import org.apache.dubbo.common.logger.Level;
import org.apache.dubbo.common.utils.DubboAppender;
import org.apache.dubbo.common.utils.LogUtil;
import org.apache.dubbo.rpc.AppResponse;
@@ -34,7 +35,6 @@
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
-import org.apache.log4j.Level;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeEach;
diff --git a/dubbo-cluster/src/test/resources/log4j.xml b/dubbo-cluster/src/test/resources/log4j.xml
deleted file mode 100644
index 7a8fc9e55b34..000000000000
--- a/dubbo-cluster/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-cluster/src/test/resources/log4j2-test.xml b/dubbo-cluster/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-cluster/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-common/pom.xml b/dubbo-common/pom.xml
index 8f418e1a4f28..08da79fc1c23 100644
--- a/dubbo-common/pom.xml
+++ b/dubbo-common/pom.xml
@@ -105,10 +105,5 @@
cglib-nodep
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DubboAppender.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DubboAppender.java
index f9ac324c67c1..21d7478d69df 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DubboAppender.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DubboAppender.java
@@ -19,16 +19,10 @@
import java.util.ArrayList;
import java.util.List;
-import org.apache.log4j.FileAppender;
-import org.apache.log4j.spi.LoggingEvent;
-
-public class DubboAppender extends FileAppender {
-
- private static final String DEFAULT_FILE_NAME = "dubbo.log";
+public class DubboAppender {
public DubboAppender() {
super();
- setFile(DEFAULT_FILE_NAME);
}
public static boolean available = false;
@@ -47,21 +41,9 @@ public static void clear() {
logList.clear();
}
- @Override
- public void append(LoggingEvent event) {
- super.append(event);
+ public void append(Log event) {
if (available) {
- Log temp = parseLog(event);
- logList.add(temp);
+ logList.add(event);
}
}
-
- private Log parseLog(LoggingEvent event) {
- Log log = new Log();
- log.setLogName(event.getLogger().getName());
- log.setLogLevel(event.getLevel());
- log.setLogThread(event.getThreadName());
- log.setLogMessage(event.getMessage().toString());
- return log;
- }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Log.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Log.java
index 3943b67687dc..eac9df05e11f 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Log.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Log.java
@@ -16,9 +16,9 @@
*/
package org.apache.dubbo.common.utils;
-import java.io.Serializable;
+import org.apache.dubbo.common.logger.Level;
-import org.apache.log4j.Level;
+import java.io.Serializable;
public class Log implements Serializable {
private static final long serialVersionUID = -534113138054377073L;
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LogUtil.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LogUtil.java
index 5319206663d1..846b93f11c70 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LogUtil.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LogUtil.java
@@ -16,14 +16,13 @@
*/
package org.apache.dubbo.common.utils;
+import org.apache.dubbo.common.logger.Level;
import org.apache.dubbo.common.logger.Logger;
import org.apache.dubbo.common.logger.LoggerFactory;
import java.util.Iterator;
import java.util.List;
-import org.apache.log4j.Level;
-
public class LogUtil {
private static final Logger Log = LoggerFactory.getLogger(LogUtil.class);
diff --git a/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreFactoryTest.java b/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreFactoryTest.java
index 4eec702f7265..26b89c95776e 100644
--- a/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreFactoryTest.java
+++ b/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreFactoryTest.java
@@ -71,9 +71,9 @@ void testCacheContains() throws URISyntaxException {
}
private String getDirectoryOfClassPath() throws URISyntaxException {
- URL resource = this.getClass().getResource("/log4j.xml");
+ URL resource = this.getClass().getResource("/log4j2-test.xml");
String path = Paths.get(resource.toURI()).toFile().getAbsolutePath();
- int index = path.indexOf("log4j.xml");
+ int index = path.indexOf("log4j2-test.xml");
String directoryPath = path.substring(0, index);
return directoryPath;
}
diff --git a/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreTest.java b/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreTest.java
index fd2798ad330e..6bb280cc2b87 100644
--- a/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreTest.java
+++ b/dubbo-common/src/test/java/org/apache/dubbo/common/cache/FileCacheStoreTest.java
@@ -68,9 +68,9 @@ void testFileSizeExceed() throws Exception {
}
private String getDirectoryOfClassPath() throws URISyntaxException {
- URL resource = this.getClass().getResource("/log4j.xml");
+ URL resource = this.getClass().getResource("/log4j2-test.xml");
String path = Paths.get(resource.toURI()).toFile().getAbsolutePath();
- int index = path.indexOf("log4j.xml");
+ int index = path.indexOf("log4j2-test.xml");
String directoryPath = path.substring(0, index);
return directoryPath;
}
diff --git a/dubbo-common/src/test/java/org/apache/dubbo/common/utils/DubboAppenderTest.java b/dubbo-common/src/test/java/org/apache/dubbo/common/utils/DubboAppenderTest.java
index 8b4d6c4f445a..bb1f8f7a716c 100644
--- a/dubbo-common/src/test/java/org/apache/dubbo/common/utils/DubboAppenderTest.java
+++ b/dubbo-common/src/test/java/org/apache/dubbo/common/utils/DubboAppenderTest.java
@@ -16,9 +16,8 @@
*/
package org.apache.dubbo.common.utils;
-import org.apache.log4j.Category;
-import org.apache.log4j.Level;
-import org.apache.log4j.spi.LoggingEvent;
+import org.apache.dubbo.common.logger.Level;
+
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
@@ -29,19 +28,16 @@
import static org.hamcrest.Matchers.is;
import static org.junit.jupiter.api.Assumptions.assumeFalse;
import static org.junit.jupiter.api.Assumptions.assumeTrue;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
class DubboAppenderTest {
- private LoggingEvent event;
+ private Log event;
@BeforeEach
public void setUp() throws Exception {
- event = mock(LoggingEvent.class);
- when(event.getLogger()).thenReturn(mock(Category.class));
- when(event.getLevel()).thenReturn(mock(Level.class));
- when(event.getThreadName()).thenReturn("thread-name");
- when(event.getMessage()).thenReturn("message");
+ event = new Log();
+ event.setLogLevel(Level.INFO);
+ event.setLogMessage("message");
+ event.setLogThread("thread-name");
}
@AfterEach
@@ -63,7 +59,7 @@ void testAvailable() {
void testAppend() {
DubboAppender appender = new DubboAppender();
appender.append(event);
- assumeTrue(0 == DubboAppender.logList.size());
+ assumeTrue(DubboAppender.logList.isEmpty());
DubboAppender.doStart();
appender.append(event);
assertThat(DubboAppender.logList, hasSize(1));
diff --git a/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogTest.java b/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogTest.java
index 391312dab374..63dfa393c35b 100644
--- a/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogTest.java
+++ b/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogTest.java
@@ -16,7 +16,8 @@
*/
package org.apache.dubbo.common.utils;
-import org.apache.log4j.Level;
+import org.apache.dubbo.common.logger.Level;
+
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
diff --git a/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogUtilTest.java b/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogUtilTest.java
index e88e8669569f..1ecee9cb6604 100644
--- a/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogUtilTest.java
+++ b/dubbo-common/src/test/java/org/apache/dubbo/common/utils/LogUtilTest.java
@@ -16,7 +16,8 @@
*/
package org.apache.dubbo.common.utils;
-import org.apache.log4j.Level;
+import org.apache.dubbo.common.logger.Level;
+
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
diff --git a/dubbo-common/src/test/resources/log4j.xml b/dubbo-common/src/test/resources/log4j.xml
deleted file mode 100644
index 377b2a65dc3d..000000000000
--- a/dubbo-common/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-common/src/test/resources/log4j2-test.xml b/dubbo-common/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-common/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-compatible/pom.xml b/dubbo-compatible/pom.xml
index aaf41f29defa..319881b73f84 100644
--- a/dubbo-compatible/pom.xml
+++ b/dubbo-compatible/pom.xml
@@ -64,8 +64,8 @@
${project.parent.version}
- org.slf4j
- slf4j-log4j12
+ log4j
+ log4j
true
diff --git a/dubbo-compatible/src/test/resources/log4j2-test.xml b/dubbo-compatible/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-compatible/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-config/dubbo-config-api/pom.xml b/dubbo-config/dubbo-config-api/pom.xml
index 0d676105246e..5f95068a0b82 100644
--- a/dubbo-config/dubbo-config-api/pom.xml
+++ b/dubbo-config/dubbo-config-api/pom.xml
@@ -170,11 +170,6 @@
zookeeper
test
-
- org.slf4j
- slf4j-log4j12
- test
-
org.apache.dubbo
diff --git a/dubbo-config/dubbo-config-api/src/test/resources/log4j.xml b/dubbo-config/dubbo-config-api/src/test/resources/log4j.xml
deleted file mode 100644
index bfc37a80842c..000000000000
--- a/dubbo-config/dubbo-config-api/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dubbo-config/dubbo-config-spring/pom.xml b/dubbo-config/dubbo-config-spring/pom.xml
index dc82f99145ce..6cedfee3998b 100644
--- a/dubbo-config/dubbo-config-spring/pom.xml
+++ b/dubbo-config/dubbo-config-spring/pom.xml
@@ -208,12 +208,6 @@
-
- org.slf4j
- slf4j-log4j12
- test
-
-
org.apache.dubbo
diff --git a/dubbo-config/dubbo-config-spring/src/test/resources/log4j.xml b/dubbo-config/dubbo-config-spring/src/test/resources/log4j.xml
deleted file mode 100644
index 723821df246b..000000000000
--- a/dubbo-config/dubbo-config-spring/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-config/dubbo-config-spring6/pom.xml b/dubbo-config/dubbo-config-spring6/pom.xml
index 3f067b3dfd0d..fa0bfcf5d4c2 100644
--- a/dubbo-config/dubbo-config-spring6/pom.xml
+++ b/dubbo-config/dubbo-config-spring6/pom.xml
@@ -87,11 +87,6 @@
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-configcenter/dubbo-configcenter-apollo/src/test/resources/log4j2-test.xml b/dubbo-configcenter/dubbo-configcenter-apollo/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-configcenter/dubbo-configcenter-apollo/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-configcenter/dubbo-configcenter-file/src/test/resources/log4j2-test.xml b/dubbo-configcenter/dubbo-configcenter-file/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-configcenter/dubbo-configcenter-file/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-configcenter/dubbo-configcenter-nacos/src/test/resources/log4j2-test.xml b/dubbo-configcenter/dubbo-configcenter-nacos/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-configcenter/dubbo-configcenter-nacos/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-container/dubbo-container-spring/pom.xml b/dubbo-container/dubbo-container-spring/pom.xml
index 44fc43d51fa1..929316593dd6 100644
--- a/dubbo-container/dubbo-container-spring/pom.xml
+++ b/dubbo-container/dubbo-container-spring/pom.xml
@@ -40,10 +40,5 @@
org.springframework
spring-context
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-container/dubbo-container-spring/src/test/resources/log4j.xml b/dubbo-container/dubbo-container-spring/src/test/resources/log4j.xml
deleted file mode 100644
index 6bf9bd85ff3c..000000000000
--- a/dubbo-container/dubbo-container-spring/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dubbo-container/dubbo-container-spring/src/test/resources/log4j2-test.xml b/dubbo-container/dubbo-container-spring/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-container/dubbo-container-spring/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-consumer/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-consumer/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-consumer/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-provider/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-provider/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-provider/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-annotation/dubbo-demo-annotation-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-api/dubbo-demo-api-consumer/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-api/dubbo-demo-api-consumer/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-api/dubbo-demo-api-consumer/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-api/dubbo-demo-api-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-api/dubbo-demo-api-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-api/dubbo-demo-api-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-api/dubbo-demo-api-provider/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-api/dubbo-demo-api-provider/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-api/dubbo-demo-api-provider/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-api/dubbo-demo-api-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-api/dubbo-demo-api-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-api/dubbo-demo-api-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-generic-call/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-generic-call/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-generic-call/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-generic-call/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-generic-call/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-generic-call/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-native/dubbo-demo-native-consumer/src/main/resources/Log4j.properties b/dubbo-demo/dubbo-demo-native/dubbo-demo-native-consumer/src/main/resources/Log4j.properties
deleted file mode 100644
index dc3923d6e39d..000000000000
--- a/dubbo-demo/dubbo-demo-native/dubbo-demo-native-consumer/src/main/resources/Log4j.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-#
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-#
-
-log4j.rootLogger=error, console
-
-log4j.appender.console=org.apache.log4j.ConsoleAppender
-log4j.appender.console.layout=org.apache.log4j.PatternLayout
-log4j.appender.console.layout.ConversionPattern=[%-12d{HH\:mm\:ss.SS}] [%p] %l %m%n
diff --git a/dubbo-demo/dubbo-demo-native/dubbo-demo-native-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-native/dubbo-demo-native-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-native/dubbo-demo-native-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-native/dubbo-demo-native-provider/src/main/resources/Log4j.properties b/dubbo-demo/dubbo-demo-native/dubbo-demo-native-provider/src/main/resources/Log4j.properties
deleted file mode 100644
index 192673cfecc7..000000000000
--- a/dubbo-demo/dubbo-demo-native/dubbo-demo-native-provider/src/main/resources/Log4j.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-#
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-#
-
-
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-native/dubbo-demo-native-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-native/dubbo-demo-native-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-native/dubbo-demo-native-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-consumer/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-consumer/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-consumer/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-provider/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-provider/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-provider/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-spring-boot/dubbo-demo-spring-boot-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-spring-boot/pom.xml b/dubbo-demo/dubbo-demo-spring-boot/pom.xml
index 086bf44d20a3..9d6c2de8a9ad 100644
--- a/dubbo-demo/dubbo-demo-spring-boot/pom.xml
+++ b/dubbo-demo/dubbo-demo-spring-boot/pom.xml
@@ -34,7 +34,6 @@
true
2.7.17
- 1.7.33
2.7.17
1.11.5
@@ -63,11 +62,6 @@
-
- org.slf4j
- slf4j-log4j12
- ${slf4j-log4j12_version}
-
io.micrometer
micrometer-core
diff --git a/dubbo-demo/dubbo-demo-triple/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-triple/src/main/resources/log4j.properties
deleted file mode 100644
index 3fa75995b9f5..000000000000
--- a/dubbo-demo/dubbo-demo-triple/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-#
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-#
-
-###set log levels###
-log4j.rootLogger=debug, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy hh:mm:ss:sss z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-triple/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-triple/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-triple/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-jaxrs-rest-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-xml/dubbo-demo-jaxrs-rest-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-xml/dubbo-demo-jaxrs-rest-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-jaxrs-rest-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-xml/dubbo-demo-jaxrs-rest-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-xml/dubbo-demo-jaxrs-rest-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-spring-mvc-rest-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-xml/dubbo-demo-spring-mvc-rest-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-xml/dubbo-demo-spring-mvc-rest-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-spring-mvc-rest-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-xml/dubbo-demo-spring-mvc-rest-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-xml/dubbo-demo-spring-mvc-rest-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-consumer/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-consumer/src/main/resources/log4j.properties
deleted file mode 100644
index a92647d964c9..000000000000
--- a/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-consumer/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-consumer/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-consumer/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-consumer/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-provider/src/main/resources/log4j.properties b/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-provider/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-provider/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-provider/src/main/resources/log4j2.xml b/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-provider/src/main/resources/log4j2.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-demo/dubbo-demo-xml/dubbo-demo-xml-provider/src/main/resources/log4j2.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-demo/pom.xml b/dubbo-demo/pom.xml
index fea5b042e785..3b41d7ce0417 100644
--- a/dubbo-demo/pom.xml
+++ b/dubbo-demo/pom.xml
@@ -45,8 +45,8 @@
- org.slf4j
- slf4j-log4j12
+ org.apache.logging.log4j
+ log4j-slf4j-impl
diff --git a/dubbo-dependencies-bom/pom.xml b/dubbo-dependencies-bom/pom.xml
index 0c2a0fe519d2..ed0e3b312e21 100644
--- a/dubbo-dependencies-bom/pom.xml
+++ b/dubbo-dependencies-bom/pom.xml
@@ -102,7 +102,7 @@
4.4.16
1.2.83
2.0.42
- 3.7.0
+ 3.7.2
5.1.0
2.12.0
3.10.0
@@ -157,8 +157,6 @@
0.9.10
1.7.36
-
- 1.7.33
1.2
1.2.17
1.2.11
@@ -319,7 +317,7 @@
org.slf4j
- slf4j-log4j12
+ log4j-slf4j-impl
log4j
@@ -333,6 +331,10 @@
ch.qos.logback
logback-classic
+
+ org.slf4j
+ slf4j-log4j12
+
org.apache.yetus
audience-annotations
@@ -648,11 +650,6 @@
slf4j-api
${slf4j_version}
-
- org.slf4j
- slf4j-log4j12
- ${slf4j-log4j12_version}
-
commons-logging
commons-logging
@@ -688,6 +685,16 @@
log4j-core
${log4j2_version}
+
+ org.apache.logging.log4j
+ log4j-slf4j-impl
+ ${log4j2_version}
+
+
+ org.apache.logging.log4j
+ log4j-slf4j2-impl
+ ${log4j2_version}
+
com.ctrip.framework.apollo
apollo-client
diff --git a/dubbo-dependencies/dubbo-dependencies-zookeeper-curator5/pom.xml b/dubbo-dependencies/dubbo-dependencies-zookeeper-curator5/pom.xml
index 12e64cfaa8e5..a86327cb2ec4 100644
--- a/dubbo-dependencies/dubbo-dependencies-zookeeper-curator5/pom.xml
+++ b/dubbo-dependencies/dubbo-dependencies-zookeeper-curator5/pom.xml
@@ -35,25 +35,13 @@
1.5.0
1.7.36
5.1.0
- 3.8.1
+ 3.8.3
2.40.0
check
1.0.0
2.38.0
-
-
-
- org.apache.zookeeper
- parent
- ${zookeeper_version}
- pom
- import
-
-
-
-
org.apache.curator
diff --git a/dubbo-kubernetes/src/test/resources/log4j2-test.xml b/dubbo-kubernetes/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-kubernetes/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metadata/dubbo-metadata-api/src/test/resources/log4j2-test.xml b/dubbo-metadata/dubbo-metadata-api/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metadata/dubbo-metadata-api/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metadata/dubbo-metadata-definition-protobuf/src/test/resources/log4j2-test.xml b/dubbo-metadata/dubbo-metadata-definition-protobuf/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metadata/dubbo-metadata-definition-protobuf/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metadata/dubbo-metadata-processor/src/test/resources/log4j2-test.xml b/dubbo-metadata/dubbo-metadata-processor/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metadata/dubbo-metadata-processor/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metadata/dubbo-metadata-report-nacos/src/test/resources/log4j2-test.xml b/dubbo-metadata/dubbo-metadata-report-nacos/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metadata/dubbo-metadata-report-nacos/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metadata/dubbo-metadata-report-redis/src/test/resources/log4j2-test.xml b/dubbo-metadata/dubbo-metadata-report-redis/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metadata/dubbo-metadata-report-redis/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metadata/dubbo-metadata-rest/pom.xml b/dubbo-metadata/dubbo-metadata-rest/pom.xml
index dfb0b3cffc18..a9a49d6633f9 100644
--- a/dubbo-metadata/dubbo-metadata-rest/pom.xml
+++ b/dubbo-metadata/dubbo-metadata-rest/pom.xml
@@ -30,6 +30,37 @@
dubbo-metadata-rest
The rest metadata module of Dubbo project
+
+ 2.7.17
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-dependencies
+ ${spring-boot.version}
+ pom
+ import
+
+
+ org.springframework.boot
+ spring-boot-starter-logging
+ ${spring-boot.version}
+
+
+ ch.qos.logback
+ logback-classic
+
+
+ org.apache.logging.log4j
+ log4j-to-slf4j
+
+
+
+
+
+
org.apache.dubbo
diff --git a/dubbo-metadata/dubbo-metadata-rest/src/test/resources/log4j2-test.xml b/dubbo-metadata/dubbo-metadata-rest/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metadata/dubbo-metadata-rest/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-metrics-api/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-metrics-api/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-metrics-api/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-metrics-config-center/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-metrics-config-center/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-metrics-config-center/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-metrics-default/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-metrics-default/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-metrics-default/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-metrics-metadata/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-metrics-metadata/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-metrics-metadata/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-metrics-prometheus/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-metrics-prometheus/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-metrics-prometheus/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-metrics-registry/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-metrics-registry/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-metrics-registry/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-metrics/dubbo-tracing/src/test/resources/log4j2-test.xml b/dubbo-metrics/dubbo-tracing/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-metrics/dubbo-tracing/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-monitor/dubbo-monitor-common/src/test/resources/log4j2-test.xml b/dubbo-monitor/dubbo-monitor-common/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-monitor/dubbo-monitor-common/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-monitor/dubbo-monitor-default/pom.xml b/dubbo-monitor/dubbo-monitor-default/pom.xml
index b2de57b61b98..30791b1dab9e 100644
--- a/dubbo-monitor/dubbo-monitor-default/pom.xml
+++ b/dubbo-monitor/dubbo-monitor-default/pom.xml
@@ -77,10 +77,5 @@
gson
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-monitor/dubbo-monitor-default/src/test/resources/log4j.properties b/dubbo-monitor/dubbo-monitor-default/src/test/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-monitor/dubbo-monitor-default/src/test/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-monitor/dubbo-monitor-default/src/test/resources/log4j2-test.xml b/dubbo-monitor/dubbo-monitor-default/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-monitor/dubbo-monitor-default/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-auth/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-auth/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-auth/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-filter-cache/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-filter-cache/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-filter-cache/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-filter-validation/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-filter-validation/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-filter-validation/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-native/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-native/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-native/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-access-log/pom.xml b/dubbo-plugin/dubbo-plugin-access-log/pom.xml
index c295f23aff4f..b3dd64cf43c4 100644
--- a/dubbo-plugin/dubbo-plugin-access-log/pom.xml
+++ b/dubbo-plugin/dubbo-plugin-access-log/pom.xml
@@ -38,5 +38,10 @@
dubbo-config-api
${project.version}
+
+ log4j
+ log4j
+ test
+
diff --git a/dubbo-plugin/dubbo-plugin-access-log/src/test/resources/log4j.xml b/dubbo-plugin/dubbo-plugin-access-log/src/test/resources/log4j.xml
deleted file mode 100644
index eb01deaffe9d..000000000000
--- a/dubbo-plugin/dubbo-plugin-access-log/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-plugin/dubbo-plugin-access-log/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-access-log/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-access-log/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-classloader-filter/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-classloader-filter/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-classloader-filter/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-cluster-mergeable/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-cluster-mergeable/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-cluster-mergeable/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-context/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-context/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-context/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-generic-invoke/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-generic-invoke/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-generic-invoke/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-loadbalance-adaptive/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-loadbalance-adaptive/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-loadbalance-adaptive/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-loom/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-loom/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-loom/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-mock/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-mock/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-mock/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-proxy-bytebuddy/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-proxy-bytebuddy/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-proxy-bytebuddy/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-qos-trace/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-qos-trace/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-qos-trace/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-router-condition/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-router-condition/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-router-condition/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-router-mesh/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-router-mesh/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-router-mesh/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-router-script/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-router-script/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-router-script/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-router-tag/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-router-tag/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-router-tag/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-token/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-token/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-token/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-plugin-tps/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-plugin-tps/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-plugin-tps/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-qos/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-qos/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-qos/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-reactive/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-reactive/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-reactive/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-security/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-security/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-security/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-spring-security/src/test/resources/log4j2-test.xml b/dubbo-plugin/dubbo-spring-security/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-plugin/dubbo-spring-security/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-plugin/pom.xml b/dubbo-plugin/pom.xml
index ed36a4808336..b166eaf8bad4 100644
--- a/dubbo-plugin/pom.xml
+++ b/dubbo-plugin/pom.xml
@@ -67,11 +67,6 @@
${project.parent.version}
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-registry/dubbo-registry-api/pom.xml b/dubbo-registry/dubbo-registry-api/pom.xml
index 244db28d0a60..4760ab549d66 100644
--- a/dubbo-registry/dubbo-registry-api/pom.xml
+++ b/dubbo-registry/dubbo-registry-api/pom.xml
@@ -118,11 +118,5 @@
${project.parent.version}
test
-
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-registry/dubbo-registry-api/src/test/java/org/apache/dubbo/registry/client/metadata/store/MetaCacheManagerTest.java b/dubbo-registry/dubbo-registry-api/src/test/java/org/apache/dubbo/registry/client/metadata/store/MetaCacheManagerTest.java
index cd1d5312cf1a..33e142b62493 100644
--- a/dubbo-registry/dubbo-registry-api/src/test/java/org/apache/dubbo/registry/client/metadata/store/MetaCacheManagerTest.java
+++ b/dubbo-registry/dubbo-registry-api/src/test/java/org/apache/dubbo/registry/client/metadata/store/MetaCacheManagerTest.java
@@ -121,9 +121,9 @@ void testCacheDump() {
}
private String getDirectoryOfClassPath() throws URISyntaxException {
- URL resource = this.getClass().getResource("/log4j.xml");
+ URL resource = this.getClass().getResource("/log4j2-test.xml");
String path = Paths.get(resource.toURI()).toFile().getAbsolutePath();
- int index = path.indexOf("log4j.xml");
+ int index = path.indexOf("log4j2-test.xml");
String directoryPath = path.substring(0, index);
return directoryPath;
}
diff --git a/dubbo-registry/dubbo-registry-api/src/test/resources/log4j.xml b/dubbo-registry/dubbo-registry-api/src/test/resources/log4j.xml
deleted file mode 100644
index 3a4fc863c784..000000000000
--- a/dubbo-registry/dubbo-registry-api/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-registry/dubbo-registry-api/src/test/resources/log4j2-test.xml b/dubbo-registry/dubbo-registry-api/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-registry/dubbo-registry-api/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-registry/dubbo-registry-multicast/src/test/resources/log4j2-test.xml b/dubbo-registry/dubbo-registry-multicast/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-registry/dubbo-registry-multicast/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-registry/dubbo-registry-nacos/pom.xml b/dubbo-registry/dubbo-registry-nacos/pom.xml
index 6c7e7760435f..b8f8f8536aaa 100644
--- a/dubbo-registry/dubbo-registry-nacos/pom.xml
+++ b/dubbo-registry/dubbo-registry-nacos/pom.xml
@@ -74,12 +74,6 @@
test
-
- ch.qos.logback
- logback-classic
- test
-
-
org.springframework
diff --git a/dubbo-registry/dubbo-registry-nacos/src/test/resources/log4j2-test.xml b/dubbo-registry/dubbo-registry-nacos/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-registry/dubbo-registry-nacos/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-registry/dubbo-registry-zookeeper/src/test/resources/log4j2-test.xml b/dubbo-registry/dubbo-registry-zookeeper/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-registry/dubbo-registry-zookeeper/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-remoting/dubbo-remoting-api/pom.xml b/dubbo-remoting/dubbo-remoting-api/pom.xml
index a7c838e90099..a9ab59c31a14 100644
--- a/dubbo-remoting/dubbo-remoting-api/pom.xml
+++ b/dubbo-remoting/dubbo-remoting-api/pom.xml
@@ -53,10 +53,5 @@
${project.parent.version}
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-remoting/dubbo-remoting-api/src/test/resources/log4j.xml b/dubbo-remoting/dubbo-remoting-api/src/test/resources/log4j.xml
deleted file mode 100644
index 786c2732f28b..000000000000
--- a/dubbo-remoting/dubbo-remoting-api/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-remoting/dubbo-remoting-api/src/test/resources/log4j2-test.xml b/dubbo-remoting/dubbo-remoting-api/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-remoting/dubbo-remoting-api/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-remoting/dubbo-remoting-http/pom.xml b/dubbo-remoting/dubbo-remoting-http/pom.xml
index e4af576a47c7..056ad679b96a 100644
--- a/dubbo-remoting/dubbo-remoting-http/pom.xml
+++ b/dubbo-remoting/dubbo-remoting-http/pom.xml
@@ -59,11 +59,6 @@
4.5.14
test
-
- org.slf4j
- slf4j-log4j12
- test
-
com.squareup.okhttp3
diff --git a/dubbo-remoting/dubbo-remoting-http/src/test/resources/log4j.xml b/dubbo-remoting/dubbo-remoting-http/src/test/resources/log4j.xml
deleted file mode 100644
index ef26f07ab1d6..000000000000
--- a/dubbo-remoting/dubbo-remoting-http/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-remoting/dubbo-remoting-http/src/test/resources/log4j2-test.xml b/dubbo-remoting/dubbo-remoting-http/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-remoting/dubbo-remoting-http/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-remoting/dubbo-remoting-netty/pom.xml b/dubbo-remoting/dubbo-remoting-netty/pom.xml
index 300e15c07fbf..bc0bd6fa9fee 100644
--- a/dubbo-remoting/dubbo-remoting-netty/pom.xml
+++ b/dubbo-remoting/dubbo-remoting-netty/pom.xml
@@ -40,11 +40,6 @@
org.jboss.netty
netty
-
- org.slf4j
- slf4j-log4j12
- test
-
org.apache.dubbo
dubbo-serialization-hessian2
diff --git a/dubbo-remoting/dubbo-remoting-netty/src/test/resources/log4j.xml b/dubbo-remoting/dubbo-remoting-netty/src/test/resources/log4j.xml
deleted file mode 100644
index e0eda90175db..000000000000
--- a/dubbo-remoting/dubbo-remoting-netty/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dubbo-remoting/dubbo-remoting-netty/src/test/resources/log4j2-test.xml b/dubbo-remoting/dubbo-remoting-netty/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-remoting/dubbo-remoting-netty/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-remoting/dubbo-remoting-netty4/pom.xml b/dubbo-remoting/dubbo-remoting-netty4/pom.xml
index 02d3e9747e5c..aa8249273797 100644
--- a/dubbo-remoting/dubbo-remoting-netty4/pom.xml
+++ b/dubbo-remoting/dubbo-remoting-netty4/pom.xml
@@ -68,11 +68,6 @@
${project.parent.version}
test
-
- org.slf4j
- slf4j-log4j12
- test
-
io.netty
netty-transport-classes-epoll
diff --git a/dubbo-remoting/dubbo-remoting-netty4/src/test/resources/log4j.properties b/dubbo-remoting/dubbo-remoting-netty4/src/test/resources/log4j.properties
deleted file mode 100644
index 6793e10f8264..000000000000
--- a/dubbo-remoting/dubbo-remoting-netty4/src/test/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=debug, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-remoting/dubbo-remoting-netty4/src/test/resources/log4j2-test.xml b/dubbo-remoting/dubbo-remoting-netty4/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-remoting/dubbo-remoting-netty4/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-remoting/dubbo-remoting-zookeeper-curator5/src/test/resources/log4j2-test.xml b/dubbo-remoting/dubbo-remoting-zookeeper-curator5/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-remoting/dubbo-remoting-zookeeper-curator5/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-rpc/dubbo-rpc-api/pom.xml b/dubbo-rpc/dubbo-rpc-api/pom.xml
index 93c0f77cbcc2..6aae7442f79d 100644
--- a/dubbo-rpc/dubbo-rpc-api/pom.xml
+++ b/dubbo-rpc/dubbo-rpc-api/pom.xml
@@ -51,10 +51,5 @@
hessian-lite
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-rpc/dubbo-rpc-api/src/test/resources/log4j.xml b/dubbo-rpc/dubbo-rpc-api/src/test/resources/log4j.xml
deleted file mode 100644
index eb01deaffe9d..000000000000
--- a/dubbo-rpc/dubbo-rpc-api/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-rpc/dubbo-rpc-api/src/test/resources/log4j2-test.xml b/dubbo-rpc/dubbo-rpc-api/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-rpc/dubbo-rpc-api/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-rpc/dubbo-rpc-dubbo/pom.xml b/dubbo-rpc/dubbo-rpc-dubbo/pom.xml
index 8d450d04cc80..d9c14fd08453 100644
--- a/dubbo-rpc/dubbo-rpc-dubbo/pom.xml
+++ b/dubbo-rpc/dubbo-rpc-dubbo/pom.xml
@@ -91,11 +91,6 @@
javax.el
test
-
- org.slf4j
- slf4j-log4j12
- test
-
diff --git a/dubbo-rpc/dubbo-rpc-dubbo/src/test/resources/log4j.xml b/dubbo-rpc/dubbo-rpc-dubbo/src/test/resources/log4j.xml
deleted file mode 100644
index 4d4f4b696998..000000000000
--- a/dubbo-rpc/dubbo-rpc-dubbo/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-rpc/dubbo-rpc-dubbo/src/test/resources/log4j2-test.xml b/dubbo-rpc/dubbo-rpc-dubbo/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-rpc/dubbo-rpc-dubbo/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-rpc/dubbo-rpc-injvm/src/test/resources/log4j2-test.xml b/dubbo-rpc/dubbo-rpc-injvm/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-rpc/dubbo-rpc-injvm/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-rpc/dubbo-rpc-rest/pom.xml b/dubbo-rpc/dubbo-rpc-rest/pom.xml
index 88c8e4cf0884..ab82fda1cfd4 100644
--- a/dubbo-rpc/dubbo-rpc-rest/pom.xml
+++ b/dubbo-rpc/dubbo-rpc-rest/pom.xml
@@ -27,9 +27,39 @@
jar
${project.artifactId}
The rest rpc module of dubbo project
+
+ 2.7.17
false
+
+
+
+
+ org.springframework.boot
+ spring-boot-dependencies
+ ${spring-boot.version}
+ pom
+ import
+
+
+ org.springframework.boot
+ spring-boot-starter-logging
+ ${spring-boot.version}
+
+
+ ch.qos.logback
+ logback-classic
+
+
+ org.apache.logging.log4j
+ log4j-to-slf4j
+
+
+
+
+
+
org.apache.dubbo
diff --git a/dubbo-rpc/dubbo-rpc-rest/src/test/resources/log4j2-test.xml b/dubbo-rpc/dubbo-rpc-rest/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-rpc/dubbo-rpc-rest/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-rpc/dubbo-rpc-triple/pom.xml b/dubbo-rpc/dubbo-rpc-triple/pom.xml
index 7d52a6682a0a..05acd3b5934b 100644
--- a/dubbo-rpc/dubbo-rpc-triple/pom.xml
+++ b/dubbo-rpc/dubbo-rpc-triple/pom.xml
@@ -72,11 +72,6 @@
${project.parent.version}
test
-
- org.slf4j
- slf4j-log4j12
- test
-
org.apache.commons
commons-compress
diff --git a/dubbo-rpc/dubbo-rpc-triple/src/test/resources/log4j.xml b/dubbo-rpc/dubbo-rpc-triple/src/test/resources/log4j.xml
deleted file mode 100644
index ad745c5a726e..000000000000
--- a/dubbo-rpc/dubbo-rpc-triple/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dubbo-rpc/dubbo-rpc-triple/src/test/resources/log4j2-test.xml b/dubbo-rpc/dubbo-rpc-triple/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-rpc/dubbo-rpc-triple/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-serialization/dubbo-serialization-fastjson2/src/test/resources/log4j2-test.xml b/dubbo-serialization/dubbo-serialization-fastjson2/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-serialization/dubbo-serialization-fastjson2/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-serialization/dubbo-serialization-hessian2/src/test/resources/log4j2-test.xml b/dubbo-serialization/dubbo-serialization-hessian2/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-serialization/dubbo-serialization-hessian2/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-spring-boot/dubbo-spring-boot-actuator/src/test/resources/log4j2-test.xml b/dubbo-spring-boot/dubbo-spring-boot-actuator/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-spring-boot/dubbo-spring-boot-actuator/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-spring-boot/dubbo-spring-boot-autoconfigure/src/test/resources/log4j2-test.xml b/dubbo-spring-boot/dubbo-spring-boot-autoconfigure/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-spring-boot/dubbo-spring-boot-autoconfigure/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-spring-boot/dubbo-spring-boot-compatible/actuator/src/test/resources/log4j2-test.xml b/dubbo-spring-boot/dubbo-spring-boot-compatible/actuator/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-spring-boot/dubbo-spring-boot-compatible/actuator/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-spring-boot/dubbo-spring-boot-compatible/autoconfigure/src/test/resources/log4j2-test.xml b/dubbo-spring-boot/dubbo-spring-boot-compatible/autoconfigure/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-spring-boot/dubbo-spring-boot-compatible/autoconfigure/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-spring-boot/dubbo-spring-boot-starters/dubbo-zookeeper-curator5-spring-boot-starter/pom.xml b/dubbo-spring-boot/dubbo-spring-boot-starters/dubbo-zookeeper-curator5-spring-boot-starter/pom.xml
index ee3b69fe9adc..7fd88c833835 100644
--- a/dubbo-spring-boot/dubbo-spring-boot-starters/dubbo-zookeeper-curator5-spring-boot-starter/pom.xml
+++ b/dubbo-spring-boot/dubbo-spring-boot-starters/dubbo-zookeeper-curator5-spring-boot-starter/pom.xml
@@ -34,18 +34,6 @@
3.8.3
-
-
-
- org.apache.zookeeper
- parent
- ${zookeeper_version}
- pom
- import
-
-
-
-
org.apache.curator
diff --git a/dubbo-spring-boot/dubbo-spring-boot-starters/observability/autoconfigure/src/test/resources/log4j2-test.xml b/dubbo-spring-boot/dubbo-spring-boot-starters/observability/autoconfigure/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-spring-boot/dubbo-spring-boot-starters/observability/autoconfigure/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-spring-boot/pom.xml b/dubbo-spring-boot/pom.xml
index 1d072e958eb6..47a1608ca535 100644
--- a/dubbo-spring-boot/pom.xml
+++ b/dubbo-spring-boot/pom.xml
@@ -42,7 +42,6 @@
2.7.17
1.14.9
- 1.7.33
4.11.0
@@ -75,11 +74,6 @@
-
- org.slf4j
- slf4j-log4j12
- ${slf4j-log4j12_version}
-
org.mockito
mockito-core
@@ -120,12 +114,6 @@
${project.parent.version}
test
-
- org.slf4j
- slf4j-log4j12
- ${slf4j-log4j12_version}
- test
-
diff --git a/dubbo-test/dubbo-test-check/pom.xml b/dubbo-test/dubbo-test-check/pom.xml
index caaa65124394..9173c50743e5 100644
--- a/dubbo-test/dubbo-test-check/pom.xml
+++ b/dubbo-test/dubbo-test-check/pom.xml
@@ -90,7 +90,7 @@
5.1.0
- 3.6.0
+ 3.7.2
5.1.0
diff --git a/dubbo-test/dubbo-test-common/pom.xml b/dubbo-test/dubbo-test-common/pom.xml
index 9f82b3b271d8..d759f0574492 100644
--- a/dubbo-test/dubbo-test-common/pom.xml
+++ b/dubbo-test/dubbo-test-common/pom.xml
@@ -35,6 +35,10 @@
org.apache.zookeeper
zookeeper
+
+ org.apache.logging.log4j
+ log4j-slf4j-impl
+
org.apache.dubbo
diff --git a/dubbo-test/dubbo-test-common/src/main/resources/log4j2-test.xml b/dubbo-test/dubbo-test-common/src/main/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-test/dubbo-test-common/src/main/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-test/dubbo-test-modules/src/test/resources/log4j2-test.xml b/dubbo-test/dubbo-test-modules/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-test/dubbo-test-modules/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dubbo-test/dubbo-test-spring/pom.xml b/dubbo-test/dubbo-test-spring/pom.xml
index a0b4bf91cc0c..3ba048cc35da 100644
--- a/dubbo-test/dubbo-test-spring/pom.xml
+++ b/dubbo-test/dubbo-test-spring/pom.xml
@@ -130,8 +130,8 @@
${project.version}
- org.slf4j
- slf4j-log4j12
+ org.apache.logging.log4j
+ log4j-slf4j-impl
@@ -169,17 +169,14 @@
org.apache.curator
curator-framework
- compile
org.apache.curator
curator-recipes
- compile
org.apache.zookeeper
zookeeper
- compile
diff --git a/dubbo-test/dubbo-test-spring/src/main/resources/log4j.properties b/dubbo-test/dubbo-test-spring/src/main/resources/log4j.properties
deleted file mode 100644
index 8de4c4fddbb4..000000000000
--- a/dubbo-test/dubbo-test-spring/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-###set log levels###
-log4j.rootLogger=info, stdout
-###output to the console###
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.Target=System.out
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=[%d{dd/MM/yy HH:mm:ss:SSS z}] %t %5p %c{2}: %m%n
diff --git a/dubbo-xds/src/test/resources/log4j2-test.xml b/dubbo-xds/src/test/resources/log4j2-test.xml
new file mode 100644
index 000000000000..0c9b0ec100d6
--- /dev/null
+++ b/dubbo-xds/src/test/resources/log4j2-test.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pom.xml b/pom.xml
index 4212a04f4c77..4e0feb14c5f2 100644
--- a/pom.xml
+++ b/pom.xml
@@ -203,6 +203,11 @@
mockito-inline
test
+
+ org.apache.logging.log4j
+ log4j-slf4j-impl
+ test
+