camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From boday <>
Subject start/stop routes programmatically
Date Tue, 15 Dec 2009 01:15:46 GMT

I see that Camel 2.1 now support starting/stopping routes via JMX/APIs.  But,
how do I identify routes properly at runtime...

For example, assume I have the following route...


They show up in JMX as "route1" and "route2".  The description/endpointURI
fields definitely help, but might be problematic to use when there are a lot
of routes.  

The same applies to finding a routes with Camel APIs.  I can get a list of
routes using this...


I see that I can then call the following on a RouteDefinition to get to the
first endpoint name


I guess I could use this name to identify a route and then call
stop()/start() on it...but this seems like a very indirect approach to
identify it?  Am I missing something?

What I'd like to do is give a route an explicit name that can be referenced
later (in JMX/programmatically)...maybe the DescriptionDefinition class
could help, but am not sure how to use it...

something along these lines is what I'm looking for...


thanks in advance...

Ben - Senior Consultant
using SMX 3.3.1/Camel 2.0
View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message