SLF4J: Class path contains multiple SLF4J bindings.
依赖包冲突,引入的依赖包中包含了多个日志版本。在对应的依赖包中排除即可。对于不清楚具体是那个包存在依赖冲突,建议在idea中安装冲突分析插件Maven Melper,进行分析.
示例如下:
<dependency> <groupId>org.apache.zookeeper</groupId> <artifactId>zookeeper</artifactId> <version>3.4.14</version> <exclusions> <exclusion> <artifactId>slf4j-log4j12</artifactId> <groupId>org.slf4j</groupId> </exclusion> </exclusions> </dependency>