External ActiveMQ with Wildfly 9.0.1

Target of this post is to configure a vanilla Wildfly 9.0.1 to use an external vanilla ActiveMQ 5.12.0. These are the latest releases on 2015-09-18. I got it running with following steps:

  1. Download Wildfly 9.0.1 if you don’t have it already: http://download.jboss.org/wildfly/9.0.1.Final/wildfly-9.0.1.Final.zip
  2. Download ActiveMQ 5.12.0 if you don’t have it already: http://www.apache.org/dyn/closer.cgi?path=/activemq/5.12.0/apache-activemq-5.12.0-bin.zip
  3. Download ActiveMQ Resource Adapter if you don’t have it already: https://repository.apache.org/content/repositories/releases/org/apache/activemq/activemq-rar/5.9.1/activemq-rar-5.9.1.rar
  4. Extract all the downloaded files. You can place Wildfly and ActiveMQ wherever you want. The resource adapter should go to $WILDFLY/modules/org/apache/activemq/main. All files in apache-activemq-5.12.0-bin.zip should go to this folder.
  5. Edit $WILDFLY/modules/org/apache/activemq/main/META-INF/ra.xml and remove the part marked with <!– NOTE disable the following property if you do not wish to deploy an embedded broker –>
  6. Add the file $WILDFLY/modules/org/apache/activemq/main/module.xml with this content
  7. Edit $WILDFLY/standalone/configuration/standalone.xml and add the following parts:
    • Under urn:jboss:domain:ejb3:3.0 add
    • Under urn:jboss:domain:resource-adapters:3.0 add the resource adapter
  8. In your project you will need to activate javax.jms.api in your jboss-deployment-structure.xml file (placed in WEB-INF folder):
  9. Now you should be able to write your MDB like this
  10. You will find the ActiveMQ management gui under http://localhost:8161/admin/. The default credentials are admin/admin.

2 thoughts on “External ActiveMQ with Wildfly 9.0.1

  1. Hi,

    I follow your detailed explanation but without succcess. I am not able to see the queue under ActiveMQ admin console.

    Is WildFly be connected immeditaly after launch ?

    Thanks a lot.

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.