I read in TomEE documentation  here
<http://tomee.apache.org/activemqresourceadapter-config.html>   that
multiple ActiveMQResourceAdapter declarations are allowed. I tried
configuring openwire, websocket and amqp using the following config but I
get the following exception -

SEVERE: Failed to start Apache ActiveMQ (localhost, null). Reason:
javax.management.InstanceAlreadyExistsException:
org.apache.activemq:BrokerName=localhost,Type=Broker
javax.management.InstanceAlreadyExistsException:
org.apache.activemq:BrokerName=localhost,Type=Broker


*My Configuration in tomee.xml -*


<Resource id="MyWebSocketResourceAdapter" type="ActiveMQResourceAdapter">
        BrokerXmlConfig =  broker:(ws://localhost:61614) 
    ServerUrl       =  vm://localhost
</Resource>

<Resource id="MyWebSocketConnectionFactory"
type="javax.jms.ConnectionFactory">
        ResourceAdapter = MyWebSocketResourceAdapter
</Resource>



<Resource id="MyOpenwireResourceAdapter" type="ActiveMQResourceAdapter">
        BrokerXmlConfig = 
broker:(tcp://0.0.0.0:61616?maximumConnections=1000&amp;wireformat.maxFrameSize=104857600)
 
    ServerUrl       =  vm://localhost
</Resource>

<Resource id="MyOpenwireConnectionFactory"
type="javax.jms.ConnectionFactory">
        ResourceAdapter = MyOpenwireResourceAdapter
</Resource>



<Resource id="MyAMQPResourceAdapter" type="ActiveMQResourceAdapter">
        BrokerXmlConfig = 
broker:(amqp://0.0.0.0:5672?maximumConnections=1000&amp;wireformat.maxFrameSize=104857600)
 
    ServerUrl       =  vm://localhost
</Resource>

<Resource id="MyAMQPConnectionFactory" type="javax.jms.ConnectionFactory">
        ResourceAdapter = MyAMQPResourceAdapter
</Resource>

Thanks for all the help.



--
View this message in context: 
http://openejb.979440.n4.nabble.com/ActiveMQ-in-TomEE-tp4661143p4661160.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Reply via email to