java - ActiveMQ fails to create local registry when started from Maven in console -


i having trouble initializing activemq (activemq-core:5.7.0) when running unit test maven console. working fine when run intellij.

result intellij runner:

2016-07-04 14:21:22 debug jndihelper:90 - {java.naming.provider.url=vm://localhost, java.naming.factory.initial=org.apache.activemq.jndi.activemqinitialcontextfactory, java.naming.security.authentication=true} 2016-07-04 14:21:22 debug managementcontext:492 - creating rmiregistry on port 1099 2016-07-04 14:21:22 debug managementcontext:507 - not using jre 1.4: mx4j.tools.naming.namingservice 2016-07-04 14:21:22 debug managementcontext:522 - created jmxconnectorserver javax.management.remote.rmi.rmiconnectorserver@52ac6ca7 2016-07-04 14:21:22 debug managementcontext:120 - starting jmxconnectorserver... 

result mvn test:

2016-07-04 14:00:26 debug jndihelper:90 - {java.naming.provider.url=vm://localhost, java.naming.factory.initial=org.apache.activemq.jndi.activemqinitialcontextfactory, java.naming.security.authentication=true} 2016-07-04 14:00:26 debug managementcontext:509 - failed create local registry. exception ignored.     java.lang.nosuchmethoderror: org.slf4j.helpers.messageformatter.format(ljava/lang/string;ljava/lang/object;)ljava/lang/string;             @ org.slf4j.impl.log4jloggeradapter.debug(log4jloggeradapter.java:223)             @ org.apache.activemq.broker.jmx.managementcontext.createconnector(managementcontext.java:492)             @ org.apache.activemq.broker.jmx.managementcontext.findtigermbeanserver(managementcontext.java:4     ...     2016-07-04 14:35:16 error managementcontext:423 - failed initialize mbeanserver     java.lang.nosuchmethoderror: org.slf4j.helpers.messageformatter.format(ljava/lang/string;ljava/lang/object;)ljava/lang/string;     ...     2016-07-04 14:35:16 debug managementcontext:107 - error invoking start on mbean null. exception ignored.     java.lang.nullpointerexception             @ org.apache.activemq.broker.jmx.managementcontext.start(managementcontext.java:102)             @ org.apache.activemq.broker.brokerservice.startmanagementcontext(brokerservice.java:2367)     ... 

infrastructure using:

<infrastructure name="localhost" host="vm://localhost"                         port="0" channel="" connectiontype="jndi" connectionfactory="connectionfactory"                         contextfactory="org.apache.activemq.jndi.activemqinitialcontextfactory"                         reconnectinterval="30" reconnectintervaltimeunit="seconds"                         reconnectattempts="30" /> 


Comments

Popular posts from this blog

java - Static nested class instance -

c# - Bluetooth LE CanUpdate Characteristic property -

JavaScript - Replace variable from string in all occurrences -