When setting up NServiceBus with MSMQ using the standard IServer config options, you define:
- an input queue
- an error queue.
When your NServiceBus Message Handler fails handling the message for whatever reason, it throws an exception and moves the message to the error queue.
Is the message in the error queue the exact same message that was in the input queue? If so, which I imagine it is, is there any way to know why those messages failed? Is there any metadata attached to them that might contain the original exception that was thrown?
Being able to do this would be especially useful in scenarios when your Handler is set to retry a number of times greater than one. This is because even if fatal errors might be thrown in the Handler, and logged, they're not really Fatal as such until they go in the error queue, because that's when they've actually failed.
Any ideas?
cheers