camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Block <>
Subject Re: Is there any way to unschedule the Camel quartz job
Date Fri, 05 Jun 2015 17:32:54 GMT
Take a look at the Control Bus [1] which provides the functionality to start/stop routes from
another route.

- Andy

[1] -

Andrew Block

On June 5, 2015 at 11:41:24 AM, Akram ( wrote:

I am triggering the quartz cron scheduler in one route. The requirement is to  
stop/remove the scheduled quartz job from another route. I have tried the  
below code but in vain.  
//Quartz route  

//Another route to stop the quartz scheduler  
.beanRef("processor", "StopRoute")  

//Stop Route method  
/public void stopRoute(Exchange exchange) throws Exception {  
CamelContext context = exchange.getContext();  
ServiceStatus status =  
if (!(status == ServiceStatus.Stopped || status ==  
ServiceStatus.Stopping)) {  
exchange.getOut().setBody(ROUTE_NAME+" is already in stopped  


Quartz route is not stopping and Scheduled job is still running.  

View this message in context:
Sent from the Camel - Users mailing list archive at  

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message