[
https://issues.apache.org/jira/browse/RATIS-508?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16964133#comment-16964133
]
Tsz-wo Sze commented on RATIS-508:
----------------------------------
Here is what I have tried:
{code}
index ed1ef3be..34c78a9d 100644
--- a/pom.xml
+++ b/pom.xml
@@ -382,7 +382,6 @@
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
- <scope>test</scope>
</dependency>
<dependency>
{code}
And the result is
{code}
[INFO] -------------------< org.apache.ratis:ratis-common >--------------------
[INFO] Building Apache Ratis Common 0.5.0-SNAPSHOT [3/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-common:jar:0.5.0-SNAPSHOT
[INFO] | \- log4j:log4j:jar:1.2.17:test XXX
[INFO]
[INFO] -------------------< org.apache.ratis:ratis-client >--------------------
[INFO] Building Apache Ratis Client 0.5.0-SNAPSHOT [4/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-client:jar:0.5.0-SNAPSHOT
[INFO]
[INFO] -------------------< org.apache.ratis:ratis-metrics >-------------------
[INFO] Building Apache Ratis Metrics 0.5.0-SNAPSHOT [5/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-metrics:jar:0.5.0-SNAPSHOT
[INFO] | \- log4j:log4j:jar:1.2.17:test XXX
[INFO]
[INFO] -------------------< org.apache.ratis:ratis-server >--------------------
[INFO] Building Apache Ratis Server 0.5.0-SNAPSHOT [6/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-server:jar:0.5.0-SNAPSHOT
[INFO] +- log4j:log4j:jar:1.2.17:test XXX
[INFO]
[INFO] --------------------< org.apache.ratis:ratis-grpc >---------------------
[INFO] Building Apache Ratis gRPC Support 0.5.0-SNAPSHOT [8/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-grpc:jar:0.5.0-SNAPSHOT
[INFO] | \- log4j:log4j:jar:1.2.17:test XXX
[INFO]
[INFO] --------------------< org.apache.ratis:ratis-netty >--------------------
[INFO] Building Apache Ratis Netty Support 0.5.0-SNAPSHOT [9/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-netty:jar:0.5.0-SNAPSHOT
[INFO] \- log4j:log4j:jar:1.2.17:test XXX
[INFO]
[INFO] -------------------< org.apache.ratis:ratis-hadoop >--------------------
[INFO] Building Apache Ratis Hadoop Support 0.5.0-SNAPSHOT [10/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-hadoop:jar:0.5.0-SNAPSHOT
[INFO] | \- log4j:log4j:jar:1.2.17:compile XXX
[INFO]
[INFO] --------------------< org.apache.ratis:ratis-test >---------------------
[INFO] Building Apache Ratis Test 0.5.0-SNAPSHOT [11/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-test:jar:0.5.0-SNAPSHOT
[INFO] +- log4j:log4j:jar:1.2.17:test XXX
[INFO]
[INFO] ------------------< org.apache.ratis:ratis-examples >-------------------
[INFO] Building Apache Ratis Examples 0.5.0-SNAPSHOT [12/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-examples:jar:0.5.0-SNAPSHOT
[INFO] +- log4j:log4j:jar:1.2.17:compile XXX
[INFO]
[INFO] ---------------< org.apache.ratis:ratis-replicated-map >----------------
[INFO] Building Apache Ratis Replicated Map 0.5.0-SNAPSHOT [13/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-replicated-map:jar:0.5.0-SNAPSHOT
[INFO] | \- log4j:log4j:jar:1.2.17:compile XXX
[INFO]
[INFO] -----------------< org.apache.ratis:ratis-logservice >------------------
[INFO] Building Apache Ratis LogService 0.5.0-SNAPSHOT [14/15]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] org.apache.ratis:ratis-logservice:jar:0.5.0-SNAPSHOT
[INFO] | +- log4j:log4j:jar:1.2.17:compile XXX
[INFO]
[INFO] ------------------< org.apache.ratis:ratis-assembly >-------------------
[INFO] Building Apache Ratis Project Assembly 0.5.0-SNAPSHOT [15/15]
[INFO] --------------------------------[ pom ]---------------------------------
[INFO] org.apache.ratis:ratis-assembly:pom:0.5.0-SNAPSHOT
[INFO] | \- log4j:log4j:jar:1.2.17:compile XXX
{code}
> Switch from log4j to slf4j
> --------------------------
>
> Key: RATIS-508
> URL: https://issues.apache.org/jira/browse/RATIS-508
> Project: Ratis
> Issue Type: Improvement
> Components: common
> Affects Versions: 0.4.0
> Reporter: Hai Zhou
> Assignee: Henrik Hegardt
> Priority: Major
> Fix For: 0.5.0
>
> Attachments: RATIS-508.001.patch, RATIS-508.002.patch
>
>
> Improve the request to raise the abstraction level of our logging framework
> so that logging is done through slf4j instead of directly through log4j.
> This will allow users to swap-out the underlying logging framework, giving a
> choice of log4j, logback-classic, and log4j2.
> eg.
> In my project, I use logback, which conflicts with log4j.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)