Hi

In the future you should post these kind of using Camel questions on
the @user mailing list.
The @dev is for Camel team to discuss developing Camel itself.


However about your question.
What version of Camel are you using?



On Sun, Dec 11, 2011 at 10:16 PM, jackkirsten <jkfrie...@hotmail.com> wrote:
> Hi, I have the following OnException blocks for both generic checked
> exception and runtime exceptions.  When I purposely throw the runtime
> exception such as (NullPointerException) from the process method, only
> Exception.class block is executed and NOT the Runtime.Exception block.  Why
> is it doing this?  How do I fix this so that the appropriate exceptions go
> to the correct onException blocks?
>
> from("seda://OrderID")
>    .routeId("OrderProcessorRoute")
> *    .onException(RuntimeException.class).maximumRedeliveries(0)
>        .handled(true)
>        .log("***** Some Runtime Exceptions Occured. *****")
>        .inOut("direct:exceptionHandling")
>        .end()
>    .onException(Exception.class).maximumRedeliveries(5)
>        .redeliveryDelay(6000)
>        .handled(true)
>        .log("***** Some Checked Exceptions Occured. *****")
>       .inOut("direct:exceptionHandling")
>       .end()
> *
>        .transacted("TestTXPolicy")
>                .inOut("bean:OrderProcessor?method=processStep1")
>                .inOut("bean:OrderProcessor?method=processStep2")
>
> Thanks, Jack
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/Camel-OnException-handling-tp5066566p5066566.html
> Sent from the Camel Development mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
FuseSource
Email: cib...@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/

Reply via email to