报错信息:
LoggerFactory is not a Logback LoggerContext but Logback is on the classpath. Either remove Logback or the competing implementation (class org.slf4j.impl.Log4jLoggerFactory loaded from file:/D:/softinstall/apache-maven-3.6.3-bin/apache-maven-3.6.3/mavenlib/org/slf4j/slf4j-log4j12/1.7.29/slf4j-log4j12-1.7.29.jar). If you are using WebLogic you will need to add ‘org.slf4j’ to prefer-application-packages in WEB-INF/weblogic.xml: org.slf4j.impl.Log4jLoggerFactory
报错原因:
因为jar包冲突
解决办法:
找到对应的jar包,把冲突的jar包删除即可(如我的为D:/softinstall/apache-maven-3.6.3-bin/apache-maven-3.6.3/mavenlib/org/slf4j/slf4j-log4j12/1.7.29/slf4j-log4j12-1.7.29.jar)直接把1.7.29目录删除
springboot项目报错LoggerFactory is not a Logback LoggerContext but Logback is on the classpath. Either r
最新推荐文章于 2024-06-11 17:08:09 发布