camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Stopping long redelivery on Camel shutdown
Date Thu, 21 Jun 2012 06:36:59 GMT
Hi

This has been improved in Camel 2.9.1 onwards
https://issues.apache.org/jira/browse/CAMEL-4950

- Graceful Shutdown is now more aggressive if timeout occurred during
shutdown, rejecting continued processing of messages or redeliveries.

There is a default timeout of 5 minutes in the graceful shutdown. You
can customize this, for example to a lower value.
Then Camel shutdown will force a shutdown when the  timeout is hit.
http://camel.apache.org/graceful-shutdown.html






On Wed, Jun 20, 2012 at 9:21 PM, CraigLaSalle <craig.lasalle@gmail.com> wrote:
> Hi Camel Experts -
>
> I have a route that uses the HTTP component to call a web service. If the
> HTTP component returns
> "org.apache.camel.component.http.HttpOperationFailedException", then the
> <onException> definition specifies to attempt redeliveries.
>
> The RedeliveryPolicy specifies a redelivery delay of 15 seconds, a maximum
> redeliveries of 480, for a total wait time of 2 hours.
>
>        <onException>
>
> <exception>org.apache.camel.component.http.HttpOperationFailedException</exception>
>            <redeliveryPolicy redeliveryDelay="15000"
> maximumRedelivers="480" />
>            <handled>
>                <constant>true</constant>
>            </handled>
>        </onException>
>
> The problem is on shutdown. The Camel shutdown flow will wait for any
> inflight messages that are in the "redelivery loop" to complete, which of
> course can be several hours. We want to be able to shutdown the component in
> a much shorter time without the long wait, gracefully.
>
> QUESTION: Is there a way to terminate the redelivery of the messages when
> Camel is shutdown?
>
> Thanks,
> -Craig LaSalle
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Stopping-long-redelivery-on-Camel-shutdown-tp5714773.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

Mime
View raw message