Likely, this is a network configuration issue, not JBoss JMS-specific.
You can turn on tracing (log4j.xml) and should see messages logged saying the connection was broken.
I'm not sure what WSMQ is.
WSMQ stands for WebSphere MQ (i.e. MQ Series)
Unfortunately the network connection is never broken (there are 2 other sockets open all the time !!!) and as I mentioned before there are no exceptions in log files.
I noticed that if there are no messages in the queue for a few hours and then a message is sent to the queue the connection (1 out of 3 sockets) is closed and JBoss no longer receives any messages. It seems JBoss has no idea that the connection was lost and does not try to reconnect.
Is there any way to monitor it and force JBoss to connect again to the queue ? If it is restarted it works fine again.
JBoss's MDB already registers a Connection.setExceptionListener()
on the WSMQ connection (as defined by the JMS api).
If WSMQ doesn't report any error, there is nothing JBoss can do about it.
If WSMQ does report an error, JBoss will try to reconnect
(once every 10 seconds by default - see reconnect interval in standardjboss.xml).
Thanks for info, now I am pretty sure it is WSMQ fault and it does not report anything :(
Could you tell me what the best way to investigate it further is?
Find out how to debug WSMQ.
If you are going to use WSMQ make sure you can get some support for it.