This is an automated email from the ASF dual-hosted git repository. dongjoon pushed a commit to branch branch-1.8 in repository https://gitbox.apache.org/repos/asf/orc.git
The following commit(s) were added to refs/heads/branch-1.8 by this push: new 6540fc7a1 ORC-1282: Add `slf4j-simple` to avoid warning messages in Java tools 6540fc7a1 is described below commit 6540fc7a1281adc41af132e34d6c1e73296bdb2e Author: deshanxiao <deshanx...@microsoft.com> AuthorDate: Tue Oct 4 13:54:12 2022 -0700 ORC-1282: Add `slf4j-simple` to avoid warning messages in Java tools ### What changes were proposed in this pull request? This PR aims to add slf4j-impl to avoid warning message in Java tools. ### Why are the changes needed? When we use Orc tools, the following error will show in output: ``` java -jar ./java/tools/orc-tools-1.9.0-SNAPSHOT-uber.jar meta SLF4J: No SLF4J providers were found. SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See https://www.slf4j.org/codes.html#noProviders for further details. SLF4J: Class path contains SLF4J bindings targeting slf4j-api versions 1.7.x or earlier. SLF4J: Ignoring binding found at [jar:file:/home/deshanxiao/orc-code/build/java/tools/orc-tools-1.9.0-SNAPSHOT-uber.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: See https://www.slf4j.org/codes.html#ignoredBindings for an explanation. Error : ORC files are not specified ``` This is caused by slf4j not specifying a specific implementation. We introduce `slf4j-simple` to solve the problem because #1132 has replaced all slf4j-impl to slf4j-simple for the deprecation of log4j1. ### How was this patch tested? UT Closes #1266 from deshanxiao/deshan/fix-log. Authored-by: deshanxiao <deshanx...@microsoft.com> Signed-off-by: Dongjoon Hyun <dongj...@apache.org> (cherry picked from commit aaabad99c106c855f33aea3fe99ac92836b79970) Signed-off-by: Dongjoon Hyun <dongj...@apache.org> --- java/tools/pom.xml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/java/tools/pom.xml b/java/tools/pom.xml index 28d9827c5..e8779bd61 100644 --- a/java/tools/pom.xml +++ b/java/tools/pom.xml @@ -98,6 +98,12 @@ <artifactId>junit-jupiter-api</artifactId> <scope>test</scope> </dependency> + + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>${slf4j.version}</version> + </dependency> </dependencies> <build> @@ -187,6 +193,7 @@ <configuration> <ignoredUnusedDeclaredDependencies> <ignoredUnusedDeclaredDependency>com.google.guava:guava</ignoredUnusedDeclaredDependency> + <ignoredUnusedDeclaredDependency>org.slf4j:slf4j-simple</ignoredUnusedDeclaredDependency> </ignoredUnusedDeclaredDependencies> <ignoredDependencies> <ignoredDependency>org.apache.hadoop:hadoop-client-api</ignoredDependency>