I have created test route and what I want to achieve is:
1. Have redelivery policy set to =3
2. If Retry fails do some logic(logging,sending mail)
3. Send original message to DeadLetterQueue, so I can later on move it back to queue
I could use DeadLetterChannel from errorHandler for delivery to queue if it is used without
But I was expecting that errorHandler will pick up exception after adding onException as
handled = false in onException.
I wouldnt use onException , errorHandler would be ok if I could do some operations
such as sending email before sending to DeadLetter.
<log message="Exception has occured message Body: $"/>
When exception occurs and there is an onException then that is used, if not, then the error handler is used.