activemq使用logback日志组件 将activemq-all替换为以下配置即可 <dependency><groupId>org.apache.activemq</groupId><artifactId>activemq-spring</artifactId><version>5.10.2</version></dependency>
最近在维护一个项目的时候,发现logback日志配置没起到任何作用,在启动系统的时候发现了这么一段警告信息: SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/E:/apache-tomcat-8.5.30_4_idea/webapps/ROOT/WEB-INF/lib/activemq-all-5.7.0.jar!/org/slf4j/impl/St...
<artifactId>logback-classic</artifactId> <version>1.1.3</version> </dependency> 如上配置会报如下警告,导致log日志无法打印。 SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/D:/tools/apache-tomcat-7.0.54/webapps/test/WEB-INF/lib/activemq-all-5.10.2....
-- Logging --> <logback.version>1.0.13</logback.version> <slf4j.version>1.7.5</slf4j.version> <!-- Test --> <junit.version>4.11</junit.version> </properties> <dependencies> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context</artifactId> <version>${spring-...
SLF4J: Found binding in [jar:file:/D:/repository/ch/qos/logback/logback-classic/1.0.13/logback-classic-1.0.13.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: Found binding in [jar:file:/D:/repository/org/apache/activemq/activemq-all/5.10.0/activemq-all-5.10.0.jar!/org/slf4j/...
默认是logback; 2. 进行初始化之前的一些工作(详情可以自己去看下源码) 1. 2. private void onApplicationStartingEvent(ApplicationStartingEvent event) { this.loggingSystem = LoggingSystem.get(event.getSpringApplication().getClassLoader()); this.loggingSystem.beforeInitialize(); } 1. 2. 3. 4. 2) ...
qos.logback</groupId> <artifactId>logback-classic</artifactId> <version>1.2.3</version> </dependency> <dependency> <groupId>org.projectlombok</groupId> <artifactId>lombok</artifactId> <version>1.16.18</version> <scope>provided</scope> </dependency> <dependency> <groupId>junit</groupId> ...
activemq-starter插件的日志组件使用的是logback,我不太会用,就继续用我的log4j2,因此将他排除掉了。 producer-sample application.properties spring.activemq.broker-url=tcp://192.168.0.100:61616spring.activemq.user=admin spring.activemq.password=admin ...
检查日志配置文件: 检查工程中的日志配置文件,确保正确设置和导入SLF4J绑定。建议使用与ActiveMQ兼容的日志配置文件,例如log4j.xml或logback.xml。 测试和调试: 在本地环境中测试工程,确保问题已解决。如果仍然遇到问题,请使用调试工具,如IDEA的Debug功能,进行更详细的调试。
检查你的logback或log4j配置文件,确保日志级别和输出格式正确。 数据库连接:如果你的项目需要连接数据库,确保数据库连接配置正确,并且数据库服务正在运行。 其他插件冲突:如果你的项目中使用了其他插件,如MyBatis、Hibernate等,它们可能与Spring或ActiveMQ存在冲突。尝试禁用其他插件,以确定是否存在冲突。 缺少必要权限:...