This week's giveaway is in the EJB and other Java EE Technologies forum. We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line! See this thread for details.
I've completely the integration of MDBs on JBoss using ActiveMQ and everything works fine. In particular:
The header of my MDB has references to the ActiveMQ Adapter
Added activemq-jms-ds.xml to the deploy directory and configured it properly
Created directory activemq-rar-5.2.0.rar in the deploy directory and configured it properly
My question is this... without breaking the current setup, how do I allow an MDB to connect to a remote ActiveMQ instance?
Also, let's say I want to run ActiveMQ as a stand alone process outside of JBoss. Is there a simple switch to turn off ActiveMQ from starting up without breaking the connectors? Every time I tried to turn off ActiveMQ, my MDBs failed to deploy properly. Basically, I'd like the connector aspect of ActiveMQ to be used with the server as being optional.
Figured it out, all the changes can be made in:
To use a remote source, change the resourceadapter/config-property ServerURL to something like this:
Where myServer is the address of the remote server.
The second step to disable the embedded broker is to disable the resourceadapter/config-property BrokerXmlConfig section all together. It's the one that calls the broker-config.xml file in the JBoss solution. Removing this section will keep the connector in tact but not cause the broker to start.