File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
fluss-server/src/main/java/org/apache/fluss/server/utils Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 1717
1818package org .apache .fluss .server .utils ;
1919
20+ import org .slf4j .Logger ;
21+ import org .slf4j .LoggerFactory ;
22+
2023/** Utility class to shut down log system. */
2124public class LogShutdownUtil {
2225
26+ private static final Logger LOG = LoggerFactory .getLogger (LogShutdownUtil .class );
27+
2328 public static void shutdownLogIfPossible () {
2429 // To avoid binding to a specific logging implementation, we use reflection here.
2530 try {
@@ -29,10 +34,9 @@ public static void shutdownLogIfPossible() {
2934 Class <?> logManager = Class .forName ("org.apache.logging.log4j.LogManager" );
3035 logManager .getMethod ("shutdown" ).invoke (null );
3136 } catch (ClassNotFoundException e ) {
32- System . err . println ("Class org.apache.logging.log4j.LogManager not found" );
37+ LOG . error ("Class org.apache.logging.log4j.LogManager not found" , e );
3338 } catch (Exception e ) {
34- System .err .println (
35- "Error to invoke shutdown method of org.apache.logging.log4j.LogManager" );
39+ LOG .error ("Error to invoke shutdown method of org.apache.logging.log4j.LogManager" , e );
3640 }
3741 }
3842}
You can’t perform that action at this time.
0 commit comments