You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kyuubi.apache.org by ch...@apache.org on 2023/04/23 02:11:10 UTC

[kyuubi] branch branch-1.7 updated: [KYUUBI #4407][FOLLOWUP] Adapt SLF4J2

This is an automated email from the ASF dual-hosted git repository.

chengpan pushed a commit to branch branch-1.7
in repository https://gitbox.apache.org/repos/asf/kyuubi.git


The following commit(s) were added to refs/heads/branch-1.7 by this push:
     new 84fe0c4c1 [KYUUBI #4407][FOLLOWUP] Adapt SLF4J2
84fe0c4c1 is described below

commit 84fe0c4c1006e91e7f45d4257233b99801d0302d
Author: Cheng Pan <ch...@apache.org>
AuthorDate: Sun Apr 23 10:10:13 2023 +0800

    [KYUUBI #4407][FOLLOWUP] Adapt SLF4J2
    
    ### _Why are the changes needed?_
    
    `StaticLoggerBinder.getSingleton.getLoggerFactoryClassStr` is not valid in SLF4J, this is a missing place in the original PR.
    
    ### _How was this patch tested?_
    - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible
    
    - [ ] Add screenshots for manual tests if appropriate
    
    - [x] [Run test](https://kyuubi.readthedocs.io/en/master/develop_tools/testing.html#running-tests) locally before make a pull request
    
    Closes #4750 from pan3793/4407.
    
    Closes #4407
    
    6b8fe9603 [Cheng Pan] [KYUUBI #4407][FOLLOWUP] Adapt SLF4J2
    
    Authored-by: Cheng Pan <ch...@apache.org>
    Signed-off-by: Cheng Pan <ch...@apache.org>
    (cherry picked from commit 06dd7d3754ee210f7744e46030965a6f5df1953b)
    Signed-off-by: Cheng Pan <ch...@apache.org>
---
 .../scala/org/apache/kyuubi/operation/log/LogDivertAppender.scala    | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/kyuubi-common/src/main/scala/org/apache/kyuubi/operation/log/LogDivertAppender.scala b/kyuubi-common/src/main/scala/org/apache/kyuubi/operation/log/LogDivertAppender.scala
index 7d2989303..58bca992c 100644
--- a/kyuubi-common/src/main/scala/org/apache/kyuubi/operation/log/LogDivertAppender.scala
+++ b/kyuubi-common/src/main/scala/org/apache/kyuubi/operation/log/LogDivertAppender.scala
@@ -17,7 +17,7 @@
 
 package org.apache.kyuubi.operation.log
 
-import org.slf4j.impl.StaticLoggerBinder
+import org.slf4j.LoggerFactory
 
 import org.apache.kyuubi.Logging
 
@@ -30,9 +30,8 @@ object LogDivertAppender extends Logging {
         Log4j12DivertAppender.initialize()
       } else {
         warn(s"Unsupported SLF4J binding" +
-          s" ${StaticLoggerBinder.getSingleton.getLoggerFactoryClassStr}")
+          s" ${LoggerFactory.getILoggerFactory.getClass.getName}")
       }
     }
-
   }
 }