SLF4J: Class path contains multiple SLF4J bindings. 問題原因及解決方法。
問題
springboot專案,使用了slf4j,當引入zookeeper之後,就會報錯:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/Users/silence.hu/.m2/repository/org/slf4j/slf4j-log4j12/1.7.25/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/Users/silence.hu /.m2/repository/org/apache/logging/log4j/log4j-slf4j-impl/2.10.0/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]
由問題可以看出,是因為有多種SLFJ實現的繫結:logback-classic
slf4j-log4j12
. 因為我是引入zookeeper後才報的錯,因此可以肯定是引入zookeeper後才起的jar包衝突,因此將zookeeper中的
slf4j-log4j12
排除掉就好。
<!--zookeeper-->
<dependency>
<groupId>org.apache.zookeeper</groupId>
<artifactId>zookeeper</artifactId>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</exclusion>
</exclusions>
</dependency>
相關推薦
SLF4J: Class path contains multiple SLF4J bindings. 問題原因及解決方法。
問題 springboot專案,使用了slf4j,當引入zookeeper之後,就會報錯: SLF4J: Class path contains multiple SLF4J bindings.
Hbase啟動過程中,提示SLF4J: Class path contains multiple SLF4J bindings.
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option PermSize=128m; support was removed in 8.0 Java HotSpot(TM) 64-Bit Server VM warning: ignori
SLF4J: Class path contains multiple SLF4J bindings.
含義為: 發生jar包衝突了: 分別為: file:/C:/Users/Administrator/.m2/repository/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3.jar!/org/slf4j/i
SLF4J: Class path contains multiple SLF4J bindings 錯誤
SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [zip:E:/newbea/user_projects/domains/base_domain/servers/AdminServer/tmp/_WL_us
Idea編譯報錯:SLF4J: Class path contains multiple SLF4J bindings.
1.問題描述 idea編譯java報錯: log4j:WARN No appenders could be found for logger (org.apache.hadoop.metrics2.lib.MutableMetricsFactory). log4j:WAR
解決HBase SLF4J: Class path contains multiple SLF4J bindings.
今天啟動HBase,輸入status後,跳出如下內容: 提示很清楚了,說Class path包含了多個SLF4J的繫結。分別在目錄:/usr/local/hbase/lib和/usr/local/hadoop/hadoop-1.0.3/lib下,解決的辦法
SLF4J: Class path contains multiple SLF4J bindings.問題解決方案
錯誤提示 SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:
Hbase SLF4J: Class path contains multiple SLF4J bindings 錯誤
SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [zip:E:/newbea/user_projects/domains/base_domain/servers/AdminServer/tmp/_WL_us
SLF4J: Class path contains multiple SLF4J bindings(log4j與logback衝突了)
當你啟動service或者web專案的時候,出現瞭如下詳細地異常,那說明你配置的log4j與logback jar包發生了衝突:SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding i
使用logback時,出現Maven SLF4J: Class path contains multiple SLF4J bindings
一般出現這種情況是由於logback的版本低所致,升級到高版本,還會出現這個問題,如果確認有多個實現,如下: SLF4J: Class path contains multiple SLF4J b
SLF4J: Class path contains multiple SLF4J providers. SLF4J: Found provider [org.slf4j.helpers.NOPSer
maven依賴: <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-nop</art
遇到Class path contains multiple SLF4J bindings.該如何解決?
錯誤表現: SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/usr/hbase/lib/slf4j-log4j12-1.6.4.jar!/org/slf4j/impl/Sta
【maven】排除maven中jar包依賴的解決過程 例子:spring cloud啟動zipkin,報錯maven依賴jar包衝突 Class path contains multiple SLF4J bindings.
一直對於maven中解決jar包依賴問題的解決方法糾結不清: 下面這個例子可以說明一個很簡單的解決方法: 專案啟動報錯: Connected to the target VM, address: '127.0.0.1:59412', transport: 'sock
Maven中日誌jar包衝突報錯:Class path contains multiple SLF4J bindings
錯誤表現: SLF4J: Class path contains multiple SLF4J bindings.SLF4J: Found binding in [jar:file:/D:/learn
Hibernate 使用log4j時報 Class path contains multiple SLF4J bindings.
在Hibernate中使用log4j時jar包衝突了,控制檯列印如下: SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found
解決maven聚合專案的Class path contains multiple SLF4J bindings.問題
錯誤資訊: SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/F:/.m2/
springboot 關於 Class path contains multiple SLF4J bindings.警告的解決
springboot 關於 Class path contains multiple SLF4J bindings.警告的解決 有一次配置好springboot專案啟動後,忽然發現有下邊的警告: SLF4J: Class path contains
Activity class {package/class} does not exist原因及解決方法
前兩天用Android Studio在測試機上編譯執行一個project時,編譯通過,執行時報錯,報錯提示主要資訊為: Activity class {.../MainActivity} does not exist. 頓時一臉懵逼,MainActivity明明存在啊,而
mysql主從同步延遲原因及解決方法
解決方案 數據庫 master 朋友 mysql MySQL主從延遲原因以及解決方案:談到MySQL數據庫主從同步延遲原理,得從mysql的數據庫主從復制原理說起,mysql的主從復制都是單線程的操作(mysql5.6版本之前),主庫對所有DDL和DML產生binlog,binlog是順序
在js文件中寫el表達式取不到值的原因及解決方法
.ajax cnblogs 一個 雙引號 ssid null 使用 ucc name 1、javascript是客戶端執行,EL是在服務端執行,而服務端比客戶端先執行,所以取不到值 2、要想獲取"${jcDropClass.jcClass.id}"的值,可以在jsp中,用一