使用maven构建项目时,如果项目中有log4j的依赖,在运行程序时可能会出现在同一个类中log4j-over-slf4j.jar和 slf4j-log4j12.jar冲突的问题: 项目报错内容为: Exception in thread "main" java.lang.ExceptionInInitializerError at org.apache.log4j.LogManager.getLogger(LogManager.java:44) at org.slf4j.…
错误信息:Detected both log4j-over-slf4j.jar AND bound slf4j-log4j12.jar on the class path, preempting StackOverflowError 场景: 产品服务器采用spring-boot框架开发,zookeeper作为微服务框架,打包完成后发现服务无法启动,tomcat启动错误日志显示如下所示: 日志文本详情: 08-Nov-2017 11:32:10.984 INFO [localhost-startS…