...
The DefaultErrorHandler is the new default error handler in Camel 2.0. It only supports a limited set of features such as catching exception and using the Exception Clause. It does not support redelivery, delays or the likes. It will propagate exceptions back to the original caller. It Unlike Dead Letter Channel it does not have any dead letter queue, and do not handle exceptions by default.
Dead Letter Channel
The Dead Letter Channel is the default error handler in Camel 1.x, which is automatically configured for you. By default Camel will redeliver at most 6 times using 1 second delay, and if the exchange failed it will be logged at ERROR level.
...
Tip | ||||
---|---|---|---|---|
| ||||
If you have marked a route as transacted using the transacted DSL then Camel will automatic use a TransactionErrorHandler. It will try to lookup the global/per route configured error handler and use it if its a |
Features support by various Error Handlers
Here is a breakdown of which features is supported by the Error Handler(s):
Feature | Supported by the following Error Handler |
---|---|
all scopes | DefaultErrorHandler, TransactionErrorHandler, Dead Letter Channel |
onException | DefaultErrorHandler, TransactionErrorHandler, Dead Letter Channel |
onWhen | DefaultErrorHandler, TransactionErrorHandler, Dead Letter Channel |
handled | DefaultErrorHandler, TransactionErrorHandler, Dead Letter Channel |
Custom ExceptionPolicy | DefaultErrorHandler, TransactionErrorHandler, Dead Letter Channel |
useOriginalBody | |
redeliverUntil | |
onRedelivery | |
dead letter queue |
Scopes
The error handler is scoped as either
...