Only if the result from beanTwo is false, should the message be routed on to
beanOne. If beanTwo returns true, no further action is to be taken, and the
route ends there. Would you recommend some other way of configuring such a
route?


Claus Ibsen-2 wrote:
> 
> Hi
> 
> I was curious why your choice route does not continue to some other
> destination if the when is true.
> If beanTwo returns true then the exchange should be routed to ... void????
> And when beanTwo returns false the exchange is routed to the otherwise
> block.
> 
> But nevertheless the exception should be caught by onException.
> 
> Remember to document on the JIRA which version of Camel you are using.
> 
> 
>    <choice>
>                                <when>
>                                        <methodCall bean="beanTwo"
> method="methodFromBeanTwo"/>
>                                </when>
>                                <otherwise>
>                                        <to
> uri="bean:beanOne?methodName=methodFromBeanOne" />
>                                </otherwise>
>                        </choice>
> 

-- 
View this message in context: 
http://www.nabble.com/Will-onException-handle-exceptions-thrown-from-%27when%27-clause--tp21033017s22882p21033855.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to