JMS message rollback and redelivery with Mule

motif

I have seen a lot of users and customers looking for a solution for this following use case – you have a JMS message in transaction inside Mule and suddenly, before committing something bad happened. You want to rollback this message and retry to deliver. If unable to commit for a specific number of times redirected to a dead letter queue (DLQ).