0
votes

I have an application deployed in Websphere which should push a message in a queue implemented in JBoss using HornetQ. That message will then be consumed by an MDB within another application (on JBoss). Is that even possible?

In summary: WAS (producer) -> JBoss (consumer)

I think yes because the protocol JMS is shared, but what are the details? should I load JBoss with MQ libraries or is it all in the way I refer to the JBoss queue from WAS? Thank you so much.

1

1 Answers

1
votes

If the MDB deployed on JBoss EAP is receiving a message from a local queue in HornetQ, then you do not need to deploy any MQ jars.

All you will need to do is write a MDB application and read the messages in your onMessage(Message msg) method. It should be really as simple as that.

You can see an example of a MDB in the jboss eap quick start . The HelloWorldQueueMDB.java class is the one you might be interested in. Follow the code in that class and modify the destination annotation value for your particular HornetQ queue name (from standalone-full.xml or standalone-full-ha.xml or the full or full-ha profile in your domain.xml file).

On a side note, JBoss EAP 6.1 is quite old. I would highly recommend upgrading to JBoss EAP 6.4.13 or later.