activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <>
Subject Re: [camel] CamelContext destruction
Date Wed, 25 Apr 2007 17:10:20 GMT
On 4/25/07, dr.jeff <> wrote:
> This is very mysterious to me. When I call builder.getRouteList() my
> DefaultCamelContext is destroyed, and another (empty) one is mysteriously
> swapped into its place. How can that happen?

So the idea is that you create a CamelContext, add routes to it, then
destroy the context when your're done.


CamelContex context = new DefaultContext();

// time passes


Its just that by default RouteBuilder will use its own context if you
don't explicitly add it to a context. (Maybe we should stop this
default behaviour to avoid confusion?)


View raw message