You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Sri <sr...@googlemail.com> on 2012/08/14 16:31:40 UTC

delay on Exception is not working

Hi,

I am using camel onException() cluase with redeliveries(3).delay(1000).

How ever I can see in the logs that it is retrying but its not considering
the delay. 

Here is my route.

onException(RestClient500SeriesException.class)
						.maximumRedeliveries(retries).delay(retryDealy)
						.process(dispatch500ErrorProcessor)


I am using Camel 2.9.1
active mq : 	5.4.1
Java 1.6_30

Regards
Sri



--
View this message in context: http://camel.465427.n5.nabble.com/delay-on-Exception-is-not-working-tp5717323.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: delay on Exception is not working

Posted by Sri <sr...@googlemail.com>.
Its redeliveryDelay() on Exception not delay()


the following routes works

onException(RestClient500SeriesException.class)
						.maximumRedeliveries(retries).redeliveryDelay(retryDelay)
						.process(dispatch500ErrorProcessor)


Thanks any way for the information.


Regards
Sri



--
View this message in context: http://camel.465427.n5.nabble.com/delay-on-Exception-is-not-working-tp5717323p5717334.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: delay on Exception is not working

Posted by Sri <sr...@googlemail.com>.
is there any other way that I can use delay , I am trying to use redelivery
policy and I am using spring java Configuration for instatiating beans 

 @Bean RedeliveryPolicy dispatcherRedeliveryPolicy(){
return policy;
}

onException(RestClient500SeriesException.class).redeliveryPolicyRef(dispatcherRedeliveryPolicy.getDelayPattern())

will it work.

Regards
Sri




--
View this message in context: http://camel.465427.n5.nabble.com/delay-on-Exception-is-not-working-tp5717323p5717328.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: delay on Exception is not working

Posted by Claus Ibsen <cl...@gmail.com>.
Maybe its the AMQ broker the retrys. Are you sure its Camel, and that
the onException is being triggered.
We got a zillion tests in camel, so I think its something wrong on your end.


On Tue, Aug 14, 2012 at 4:31 PM, Sri <sr...@googlemail.com> wrote:
> Hi,
>
> I am using camel onException() cluase with redeliveries(3).delay(1000).
>
> How ever I can see in the logs that it is retrying but its not considering
> the delay.
>
> Here is my route.
>
> onException(RestClient500SeriesException.class)
>                                                 .maximumRedeliveries(retries).delay(retryDealy)
>                                                 .process(dispatch500ErrorProcessor)
>
>
> I am using Camel 2.9.1
> active mq :     5.4.1
> Java 1.6_30
>
> Regards
> Sri
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/delay-on-Exception-is-not-working-tp5717323.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



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