博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
SLF4j多个log4j2的实现类导致日志生成不了
阅读量:4171 次
发布时间:2019-05-26

本文共 1146 字,大约阅读时间需要 3 分钟。

SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/home/link/data/server/test_tomcat_main/webapps/ROOT/WEB-INF/lib/log4j-slf4j-impl-2.10.0.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/link/data/server/test_tomcat_main/webapps/ROOT/WEB-INF/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.

SLF4J: Actual binding is of type [org.apache.logging.slf4j.Log4jLoggerFactory]

如上加载正确了,有时候会变成这样:

SLF4J: Class path contains multiple SLF4J bindings.

SLF4J: Found binding in [jar:file:/home/link/data/server/test_tomcat_main/webapps/ROOT/WEB-INF/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/link/data/server/test_tomcat_main/webapps/ROOT/WEB-INF/lib/log4j-slf4j-impl-2.10.0.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]

原因是有多个实现类,删除掉slf4j-log4j12-1.7.10.jar jar包即可

转载地址:http://juyai.baihongyu.com/

你可能感兴趣的文章
关于Metasploit 5中测试模块的移植与验证
查看>>
GoMet:Go编写的多平台Agent和控制器
查看>>
CVE-2019-11815:Linux kernel漏洞
查看>>
剥丝抽茧,层层破解!看我如何一步步绕过防火墙直至获取你的支付卡信息
查看>>
CVE-2019-0708漏洞: RDP= Really DO Patch?
查看>>
使用新型反检测技术:与MuddyWater相关的BlackWater恶意活动分析
查看>>
使用ee-outliers和Elasticsearch检测可疑子进程
查看>>
Office 365出现网络钓鱼,用户需多加注意
查看>>
MalConfScan:从已知的恶意软件家族中提取配置信息
查看>>
不死的EternalBlue(永恒之蓝)
查看>>
针对中亚地区政府部门的攻击:通过Office漏洞传播新型Hawkball后门
查看>>
Windows 10安全指南
查看>>
<<OCM实验选讲>> 第七课 Oracle数据库管理实验
查看>>
<<OCM实验选讲>> 第八课 Oracle性能优化实验
查看>>
<<OCM实验选讲>> 第十课 DG实验
查看>>
Oracle EBS R12.0.6 - 禁用Command Line JVM System Properties设置的全局Low-level logging
查看>>
Oracle EBS R12 - IE 8 打开form时碰到FRM-92050 /forms/lservlet/debug:-1错误的解决方法
查看>>
看一个大男人是怎样处理家庭矛盾的(绝对经典)(转)
查看>>
VMware6辅助启动.bat
查看>>
升级linux内核到2.6.24
查看>>