Hi

What do you want to do?

If you want to do execute some custom code when CamelContext is being
shutdown, then use event notifier, or the lifecycle strategy.

Some links
http://camel.apache.org/eventnotifier-to-log-details-about-all-sent-exchanges.html
http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/EventNotifier.html
http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/LifecycleStrategy.html
https://camel.apache.org/advanced-configuration-of-camelcontext-using-spring.html

See also camel in action book, page 403

On Thu, May 1, 2014 at 11:06 PM, John D. Ament <[email protected]> wrote:
> Hi all,
>
> I was looking for a way to have a shutdown callback.  I overrode the
> doShutdown method of DefaultShutdownStrategy, thinking it would be called
> for shutdown of the camel context.  Turns out that it's being called as a
> part of the shutdown for each route as well.
>
> Is there a more appropriate way to shutdown, but only when the context is
> being shutdown, rather than the routes?
>
> I'm using Camel 2.10.6.
>
> John



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: [email protected]
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/

Reply via email to