Details
-
Improvement
-
Status: Resolved
-
Trivial
-
Resolution: Fixed
-
None
-
None
-
Unknown
Description
The FAQ article Why is the exception null when I use onException? states that exchange.getException() returns null if onException() is used in conjunction with handled(true).
Whether it's handled or not, exchange.getException() return always null since the default error handling mechanism clears the exception already:
RedeliveryErrorHandler.deliverToFailureProcessor() - Camel 2.25.0
// we did not success with the redelivery so now we let the failure processor handle it // clear exception as we let the failure processor handle it exchange.setException(null);
I'm fairly new too Camel error handling, it would've been helpful in advance to know it.
References: