Comments below

/Claus Ibsen
Apache Camel Committer
Blog: http://davsclaus.blogspot.com/



On Wed, Nov 19, 2008 at 10:30 AM, Fush <[EMAIL PROTECTED]> wrote:
>
>
> Claus Ibsen-2 wrote:
>>
>> Hi
>>
>> a)
>> Ah that might not be clearly stated in the documentation.
>>
>> It's an *all* or *nothing* with transactions. If using transactions
>> then it's the backing system (the transaction manger) responsibility
>> to handle redelivery - not Camel. Camel in this case only supports
>> delaying a fixed delay before the rollback is triggered.
>>
>> And as you use ActiveMQ as the backing system it is the ActiveMQ
>> transaction manger that handles the redelivery. And it uses 5 or is it
>> 6 redeliveries by default. So you should configure ActiveMQ how
>> redelivery should be done.
>> So, are you basically saying that I could remove the
>> transactionErrorHandler bean from the route, and just set a
>> redeliveryPolicy on the ActiveMQConnectionFactory instead?
Yeah if you want to use transacted messaging. Then you should
configure ActiveMQ how to do redelivery.

If *not* using transacted messaging you can use all the fancy stuff Camel has.


>
>
> Claus Ibsen-2 wrote:
>>
>> b)
>> That said I turn to the onException
>>
>> Is TechnicalException and FunctionalException related as such one is
>> inherited from the other?
>> eg: FunctionalException extends TechnicalException ?
>>
>> Camel uses (by default) an instanceof test to verify which onException
>> should handle the exception.
>>
>> You might have a use-case using transactions and onException that
>> needs to be checked
>> - You have onExceptions that also is meent to supoorts catch exception
>> this exception and route it differently. And then you can have the
>> handled=true to state it's okay, newer mind the exception I have
>> handled it and the TX = OK.
>> - But it can also be used as a if this exception is thrown then only
>> retry 2 times instead of default 5 times etc.
>> - etc.
>> Both exceptions extend RuntimeException, and nothing else. So there's no
>> other relationship between them.
Thanks. Will look into this that Camel should pick the correct exception.

>
>
> Claus Ibsen-2 wrote:
>>
>> c)
>> In any case it should really only call the myOwnErrorHandler only for
>> the FunctionalException.
>>
>> I will check up on your spring XML and add it as a unit test in camel.
>> I'm curious to see what you find out about this. Thanks!
>
> --
> View this message in context: 
> http://www.nabble.com/1.5-error-handling-Spring-config-buggy-not-complete--tp20562554s22882p20576291.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>
>

Reply via email to