Class CamelJob
- java.lang.Object
-
- org.apache.camel.component.quartz.CamelJob
-
- All Implemented Interfaces:
org.quartz.InterruptableJob,org.quartz.Job
- Direct Known Subclasses:
QuartzScheduledPollConsumerJob,StatefulCamelJob
public class CamelJob extends Object implements org.quartz.Job, org.quartz.InterruptableJob
This is a Quartz Job that is scheduled by QuartzEndpoint's Consumer and will call it to produce a QuartzMessage sending to a route.
-
-
Constructor Summary
Constructors Constructor Description CamelJob()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute(org.quartz.JobExecutionContext context)protected org.apache.camel.CamelContextgetCamelContext(org.quartz.JobExecutionContext context)protected org.quartz.SchedulerContextgetSchedulerContext(org.quartz.JobExecutionContext context)voidinterrupt()protected QuartzEndpointlookupQuartzEndpoint(org.apache.camel.CamelContext camelContext, org.quartz.JobExecutionContext quartzContext)protected QuartzEndpointsearchForEndpointMatch(org.apache.camel.CamelContext camelContext, String endpointUri)
-
-
-
Method Detail
-
execute
public void execute(org.quartz.JobExecutionContext context) throws org.quartz.JobExecutionException- Specified by:
executein interfaceorg.quartz.Job- Throws:
org.quartz.JobExecutionException
-
getCamelContext
protected org.apache.camel.CamelContext getCamelContext(org.quartz.JobExecutionContext context) throws org.quartz.JobExecutionException- Throws:
org.quartz.JobExecutionException
-
getSchedulerContext
protected org.quartz.SchedulerContext getSchedulerContext(org.quartz.JobExecutionContext context) throws org.quartz.JobExecutionException- Throws:
org.quartz.JobExecutionException
-
lookupQuartzEndpoint
protected QuartzEndpoint lookupQuartzEndpoint(org.apache.camel.CamelContext camelContext, org.quartz.JobExecutionContext quartzContext) throws org.quartz.JobExecutionException
- Throws:
org.quartz.JobExecutionException
-
searchForEndpointMatch
protected QuartzEndpoint searchForEndpointMatch(org.apache.camel.CamelContext camelContext, String endpointUri)
-
interrupt
public void interrupt() throws org.quartz.UnableToInterruptJobException- Specified by:
interruptin interfaceorg.quartz.InterruptableJob- Throws:
org.quartz.UnableToInterruptJobException
-
-