It appears that some conversation was lost on this thread. I will try to add it here.
The dynamic aspect of start/stopping/editing routes is being worked on in Camel 2.0. James Strachan have created a brand new camel web console for this purpose. On the road to this he have improved the camel core to cater for starting and stopping individual routes on the fly.
In Camel 1.x you can probably only start and stop the entire Camel Context.
About the web console:
Please can you point me to an example code showing how to connect to a running broker and perform actions below from an external application :
? stopping an existing camelContext
? starting a camelContext defined in the activemq.xml file
Yeah you can connect using jconsole and stop and start the camel context.
I have tried stopping the camelContext from the jconsole, but then it disappears and I can't start it again.
The problem here might be that the jmx agent is defined within the camel-context.
<camelContext id="camel" xmlns="http://activemq.apache.org/camel/schema/spring"> <jmxAgent id="agent" createConnector="true"></jmxAgent> ... </camelContext>
Stopping the context via JMX takes down the JMX agent as well it seems to me.
Yeah stopping a camel context is stopping the entire Camel context.
But you can have multiple contexts, so you can maybe have a master context with the jmx connector, and then login to that one to stop the other one.
Yet again James is working on doing this much more dynamic in Camel 2.x.