public abstract class ErrorHandlerSupport extends org.apache.camel.support.ChildServiceSupport implements ErrorHandler
ErrorHandler implementations.| Modifier and Type | Field and Description |
|---|---|
protected Map<ExceptionPolicyKey,ExceptionPolicy> |
exceptionPolicies |
protected ExceptionPolicyStrategy |
exceptionPolicy |
| Constructor and Description |
|---|
ErrorHandlerSupport() |
| Modifier and Type | Method and Description |
|---|---|
void |
addErrorHandler(org.apache.camel.Processor errorHandler) |
void |
addExceptionPolicy(ExceptionPolicyKey key,
ExceptionPolicy policy) |
static ExceptionPolicyStrategy |
createDefaultExceptionPolicyStrategy()
Creates the default exception policy strategy to use.
|
protected ExceptionPolicy |
getExceptionPolicy(org.apache.camel.Exchange exchange,
Throwable exception)
CamelContextHelper
Attempts to find the best suited
ExceptionPolicy to be used for handling the given thrown exception. |
abstract org.apache.camel.Processor |
getOutput()
Gets the output
|
boolean |
isDeadLetterChannel()
Whether this error handler handles exhausted errors by moving the exchange to a dead letter channel.
|
void |
setExceptionPolicy(ExceptionPolicyStrategy exceptionPolicy)
Sets the strategy to use for resolving the
ExceptionPolicy to use
for handling thrown exceptions. |
abstract boolean |
supportTransacted()
Whether this error handler supports transacted exchanges or not.
|
addChildService, removeChildService, shutdown, start, stopbuild, doBuild, doFail, doInit, doLifecycleChange, doResume, doShutdown, doStart, doStop, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, suspendclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitprotected final Map<ExceptionPolicyKey,ExceptionPolicy> exceptionPolicies
protected ExceptionPolicyStrategy exceptionPolicy
public void addErrorHandler(org.apache.camel.Processor errorHandler)
public void addExceptionPolicy(ExceptionPolicyKey key, ExceptionPolicy policy)
protected ExceptionPolicy getExceptionPolicy(org.apache.camel.Exchange exchange, Throwable exception)
ExceptionPolicy to be used for handling the given thrown exception.exchange - the exchangeexception - the exception that was thrownpublic void setExceptionPolicy(ExceptionPolicyStrategy exceptionPolicy)
ExceptionPolicy to use
for handling thrown exceptions.public static ExceptionPolicyStrategy createDefaultExceptionPolicyStrategy()
public abstract boolean supportTransacted()
public boolean isDeadLetterChannel()
public abstract org.apache.camel.Processor getOutput()
Apache Camel