log4j:WARN Please initialize the log4j system properly.

log4j:WARN Please initialize the log4j system properly._第1张图片

src 下配置 log4j.properties

log4j:WARN Please initialize the log4j system properly._第2张图片
log4j.rootLogger=WARN, stdout
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d %p [%c] - %m%n

正常输出

log4j:WARN Please initialize the log4j system properly._第3张图片

你可能感兴趣的:(log4j:WARN Please initialize the log4j system properly.)