I'm not sure what the use case is for redeploying the JMS subsystem. This may be something not supported by JBossMQ.
If you can create a test case (unit test) and provide a patch, it can be fixed in an upcoming release.
Actually I don't know what the fix is. My test case is very simple:
1. write an mdb for a jms topic, process message in onMessage()
2. write a sender for the topic
4. sender send messages, see that onMessages() got
messages via print out in onMessages()
5. touch the jboss jms service.xml file, this
causes the jms destinations to be rebound again
6. send messages again (no errors or exceptions)
7. don't see any onMessage() printout at all from the MDBs
I don't see why this is not supported? given that
if you are not using MDBs, you can have a jms receiver
that catch jms exceptions and then reconnect. I thought
MDBs should have handled any jms recovery automatically ?
and my scenario is this:
1. setup a jboss with mdb + queue in hajndi
2. send messages every 5 minutes
3. destroy queue from jmx (http://localhost:8080/jmx-console/HtmlAdaptor?action=inspectMBean&name=jboss.mq.destination%3Aservice%3DQueue%2Cname%3DmyQueue)
4. create + start queue from jmx (same link)
5. send messages with client ? sent OK to queue
6. MDB does not reconnect in order to get the queue also when we do: 7. listReceivers() in the queue, we don?t see the MDB as a receiver. According to jboss configuration the MDB should have reconnected as far as I understand:
shouldnt the MDB reconnect automatically? anything i can do so that mdb will reconnect?
Stopping destinations and getting clients to reconnect is an unsupported feature in JBossMQ.
There is no mechanism to push the error to the client.
One way to solve the problem (though it isn't very good) would be to
close all connections that have active receivers
(subscribers not receivers in BasicQueue) on the destination. This would cause
the ExceptionListener to fire due to the lost connection.
But this isn't implemented.
Was this feature ever added?
As it says in READ THIS FIRST,
JBossMQ is not getting new features (unless you want to provide the patch?).
Try JBoss Messaging.