【发布时间】:2016-09-17 14:03:26
【问题描述】:
我有一个简单的 java 项目(maven)。它构建了一个 jar,我们在其上执行 main 方法。但是当我在项目上运行 mvn clean test 时,我从 log4j 得到一条日志行,说
INFO Log4j appears to be running in a Servlet environment, but there's no log4j-web module available. If you want better web container support, please add the log4j-web JAR to your web archive or server lib directory.
log4j2.xml 文件位于src/main/resources/log4j2.xml。
有什么想法吗?
【问题讨论】: