Failed to load class "org.slf4j.impl.StaticLoggerBinder"
Posted bcombettter
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Failed to load class "org.slf4j.impl.StaticLoggerBinder"相关的知识,希望对你有一定的参考价值。
调试程序出现如下错误:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
下载相应的slf4j的jar包,在slf4j官网下载,
以1.7.21版本为例。
一般只是在程序中引入了slf4j-api-1.7.21.jar文件。
解决方式如下:
解压下载的zip包中,拷贝 slf4j-nop-1.7.21.jar 文件到项目中,再build path, 就解决了。
---
<!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-api -->
<!-- 只有接口,没有实现,需要依赖log4j-->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.21</version>
</dependency>
<!-- https://mvnrepository.com/artifact/log4j/log4j -->
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-nop -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-nop</artifactId>
<version>1.7.22</version>
</dependency>
以上是关于Failed to load class "org.slf4j.impl.StaticLoggerBinder"的主要内容,如果未能解决你的问题,请参考以下文章
Failed to load or instantiate TagLibraryValidator class: org.apache.taglibs.standard.tlv.JstlCoreTLV
Failed to load class "org.slf4j.impl.StaticLoggerBinder"
Unable to load configuration.
Failed to load class "org.slf4j.impl.StaticLoggerBinder".
Failed to load class "org.slf4j.impl.StaticLoggerBinder"
failed to load class "org.sl4j.impl.StaticLoggerBinder"