org.apache.camel.processor
Class DefaultErrorHandler

java.lang.Object
  extended by org.apache.camel.impl.ServiceSupport
      extended by org.apache.camel.processor.ErrorHandlerSupport
          extended by org.apache.camel.processor.RedeliveryErrorHandler
              extended by org.apache.camel.processor.DefaultErrorHandler
All Implemented Interfaces:
AsyncProcessor, Processor, ErrorHandler, Service, ShutdownableService
Direct Known Subclasses:
LoggingErrorHandler

public class DefaultErrorHandler
extends RedeliveryErrorHandler

Default error handler

Version:

Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.camel.processor.RedeliveryErrorHandler
RedeliveryErrorHandler.RedeliveryData
 
Field Summary
 
Fields inherited from class org.apache.camel.processor.RedeliveryErrorHandler
camelContext, deadLetter, deadLetterUri, handledPolicy, logger, output, outputAsync, redeliveryPolicy, redeliveryProcessor, retryWhilePolicy, useOriginalMessagePolicy
 
Fields inherited from class org.apache.camel.processor.ErrorHandlerSupport
log
 
Constructor Summary
DefaultErrorHandler(CamelContext camelContext, Processor output, CamelLogger logger, Processor redeliveryProcessor, RedeliveryPolicy redeliveryPolicy, Predicate handledPolicy, ExceptionPolicyStrategy exceptionPolicyStrategy, Predicate retryWhile)
          Creates the default error handler.
 
Method Summary
 void process(Exchange exchange)
          Processes the message exchange
 String toString()
           
 
Methods inherited from class org.apache.camel.processor.RedeliveryErrorHandler
deliverToFailureProcessor, deliverToOnRedeliveryProcessor, doShutdown, doStart, doStop, getDeadLetter, getDeadLetterUri, getLogger, getOutput, getRedeliveryPolicy, handleException, isCancelledOrInterrupted, isDone, isUseOriginalMessagePolicy, prepareExchangeAfterFailure, prepareExchangeForContinue, prepareExchangeForRedelivery, process, processAsyncErrorHandler, processErrorHandler, shouldHandleException, supportTransacted
 
Methods inherited from class org.apache.camel.processor.ErrorHandlerSupport
addExceptionPolicy, createDefaultExceptionPolicyStrategy, customProcessorForException, getExceptionPolicy, setExceptionPolicy
 
Methods inherited from class org.apache.camel.impl.ServiceSupport
addChildService, doResume, doSuspend, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isSuspended, isSuspending, removeChildService, resume, shutdown, start, start, stop, suspend
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DefaultErrorHandler

public DefaultErrorHandler(CamelContext camelContext,
                           Processor output,
                           CamelLogger logger,
                           Processor redeliveryProcessor,
                           RedeliveryPolicy redeliveryPolicy,
                           Predicate handledPolicy,
                           ExceptionPolicyStrategy exceptionPolicyStrategy,
                           Predicate retryWhile)
Creates the default error handler.

Parameters:
camelContext - the camel context
output - outer processor that should use this default error handler
logger - logger to use for logging failures and redelivery attempts
redeliveryProcessor - an optional processor to run before redelivery attempt
redeliveryPolicy - policy for redelivery
handledPolicy - policy for handling failed exception that are moved to the dead letter queue
exceptionPolicyStrategy - strategy for onException handling
retryWhile - retry while
Method Detail

process

public void process(Exchange exchange)
             throws Exception
Description copied from interface: Processor
Processes the message exchange

Specified by:
process in interface Processor
Overrides:
process in class RedeliveryErrorHandler
Parameters:
exchange - the message exchange
Throws:
Exception - if an internal processing error has occurred.

toString

public String toString()
Overrides:
toString in class Object


Apache CAMEL