I am using synchronous notification for MQ adapters (with request and reply documents):
My requirement is to persist the message in the queue in case there is a failure during processing of the message.
Is the message going to persist in the queue in case the reply doc isn’t sent?
If I am not sending the reply doc, even though the message is removed from the queue.
But looks like Synchronous Notificaion is helpful only removing Broker from the message flow and the message will be lost once it is picked up for processing irrespective of the reply doc sent to mq.
Recently i have done same kind of implementation using MQ Synchronous notifications. You have to use the transactional MQ Connections to rollback the message to the source queue if any failure in your processing service.
In MQ Listener properties you have to set Backout Threshold=number of retries.After these many number of retries your message removed from the source queue and moved to the deadletter queue. By default Backout Threshold=1.
If you are using asynchronous listener notifications, we can not control the rollback scenario, if any failure occurs, immediately the message is moved from source queue to deadletter queue.