在log4j.xml的日志配置文件中,把日志级别从info级别调整到debug级别:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd"> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false"> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender"> <layout class="org.apache.log4j.PatternLayout"> <param name="ConversionPattern" value="[%d{dd/MM/yy hh:mm:ss:sss z}] %t %5p %c{2}: %m%n" /> </layout> </appender> <root> <level value="DEBUG" /> <!--<level value="INFO" />--> <appender-ref ref="CONSOLE" /> </root> </log4j:configuration>
如上,
<level value="DEBUG" />即可
时间: 2024-11-05 19:39:27