I'm using:

Tomcat 7
Active MQ 5.9

I have a broker configured as such:



<beans xmlns="http://www.springframework.org/schema/beans";
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
        xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
  http://activemq.apache.org/schema/core
http://activemq.apache.org/schema/core/activemq-core.xsd";>

        
        <bean
        
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
                <property name="locations">
                        
<value>file:${activemq.conf}/credentials.properties</value>
                </property>
        </bean>

        
        <broker xmlns="http://activemq.apache.org/schema/core"; useJmx="true"
                brokerName="localhost" persistent="true" 
dataDirectory="${activemq.data}">

                <destinationPolicy>
                        <policyMap>
                                <policyEntries>
                                        <policyEntry topic=">">
                                                
                                                <pendingMessageLimitStrategy>
                                                        
<constantPendingMessageLimitStrategy
                                                                limit="1000" />
                                                </pendingMessageLimitStrategy>
                                        </policyEntry>
                                </policyEntries>
                        </policyMap>
                </destinationPolicy>


                
                <managementContext>
                        <managementContext createConnector="false" />
                </managementContext>

                
                <persistenceAdapter>
                        <kahaDB directory="${activemq.data}/kahadb" />
                </persistenceAdapter>


                
                <systemUsage>
                        <systemUsage>
                                <memoryUsage>
                                        <memoryUsage percentOfJvmHeap="70" />
                                </memoryUsage>
                                <storeUsage>
                                        <storeUsage limit="100 gb" />
                                </storeUsage>
                                <tempUsage>
                                        <tempUsage limit="50 gb" />
                                </tempUsage>
                        </systemUsage>
                </systemUsage>

                
                <transportConnectors>
                        
                        <transportConnector name="openwire"
                        
uri="tcp://0.0.0.0:61616?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"
/>
                </transportConnectors>

                
                <shutdownHooks>
                        <bean 
xmlns="http://www.springframework.org/schema/beans";
class="org.apache.activemq.hooks.SpringContextHook" />
                </shutdownHooks>

        </broker>

</beans>

I start the broker in a bootstrap class as follows:

activeMqBroker = BrokerFactory.createBroker(uri);
            activeMqBroker.setUseShutdownHook(true);
            activeMqBroker.startAllConnectors();

And the minute I set the useJmx="true" my application I get the following
exception:

INFO: [127.0.0.1]:5701 [upf-dev-win-user] Address[127.0.0.1]:5701 is
SHUTTING_DOWN
ERROR ActiveMqBootstrapServiceImpl - [CorrelationId-NA] [UserId-NA]
[ApSysCd-NA] [Host-NA] [WLP-NA] [WebAnalyticsCorrelationId-NA] ActiveMQ
bootstrap issue
java.io.IOException: Transport Connector could not be registered in JMX:
org.apache.activemq:type=Broker,brokerName=localhost,connector=clientConnectors,connectorName=openwire
        at
org.apache.activemq.util.IOExceptionSupport.create(IOExceptionSupport.java:27)

I followed this post:

http://activemq.apache.org/tomcat.html

And yet no luck.



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/Tomcat-JMX-Failure-tp4678285.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to