I have a spring based application implementing DefaultMssageListenerContainer and some MDP's listening to messages on IBM websphere MQ 6.
We have set the acknowledgment mode to Client-Acknowledge in container and set the Backout threshold to 3 when we created MQ queues so that the messages are retried maximum 3 times.
I have also set BOQNAME to an error queue where messages should be moved after 3 failed tries.
The weired problem I am having is the MQ status shows UNCOM status (uncommited messages) whenever I throw a runtime exception in my onMessage event.
After this it stays UNCOM state until my program exits or after few hours of last message activity (and provided last message was processed correctly- no runtimeexception)
Additionally, while status is UNCOM- other threads cannot browse messages on DATA/ error queues which happens for even those messages which were not in UNCOM state on the queues.
And most interesting is the problem that after my program shuts down- the failed messages (which were present on ERROR queue in UNCOM state) are moved to DATA queue if the last message also threw an exception, or stay on ERROR queue (Expected behaviour) if the last message was processed correctly.
Could someone help me understand whats going on here?