On Mon, Oct 1, 2012 at 8:58 PM, gilboy <josephoto...@gmail.com> wrote:
> Hi
>
> I noticed that most endpoint consumers do something like the following:
>
> try{
>    getprocessor().process(exchange);
> } catch (exception e){
>    getExceptionHandler.handleException();
> }
>
> Assume I have a route which consumes data from an endpoint whose consumer
> uses the above logic. Also assume that the route is a simple pipeline which
> has 4 processors and I define the default error handler to have 5 retries.
>
> If an exception is thrown in the first processor will camel try to replay
> the exchange through the first processor 4 more times?
>
> I am certain that camel will try to replay the exchange if processor 2-4
> throw an exception but not clear to me how it will behave if the first
> processor throws an exception
>

The error handler in the routing engine will kick in and handle errors.
The code above is just as a fail safe for a consumer.

If you got the Camel in Action book see section 5.1.2.

And read about error handling as well (and follow the links)
http://camel.apache.org/error-handling-in-camel.html

> Thanks
> Joe
>
>
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/error-handling-query-tp5720326.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cib...@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Reply via email to