On Fri, Jan 29, 2010 at 3:13 AM, Willem Jiang <[email protected]> wrote:
> Hi,
>
> You can set the id on the RouteDefinition just like this
> <route id="route1">
> </route>
> And use this ID to access the RouteDefinition from the CamelContext.
>
> And this thread[1] will help you if you are using the DSL to define the
> route.
>
> [1]http://old.nabble.com/start-stop-routes-programmatically-ts26781725.html#a26781725
>

There are methods on CamelContext to stop/start a route by its id.


> Willem
>
> Ricardo Melo wrote:
>>
>> Hi,
>>
>> I'm new to camel API and I need to update or remove camel routes that have
>> been created.
>>
>> I've found in an example that to find current routes, I need to use the
>> code:
>> List<RouteDefinition> routes = camelContext.getRouteDefinitions();
>>
>> I can iterate through the routes definition, however how can I see the
>> "to"
>> (destination) endpoint of a route definition, to update or remove the
>> route
>> I'm looking for? Where is it?
>>
>> Thanks in advance!
>
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Reply via email to