public class ExecutionSchedulerImpl extends Object implements ExecutionScheduler
| Modifier and Type | Field and Description |
|---|---|
protected static String |
DEFAULT_SCHEDULER_NAME |
protected static boolean |
isInitialized |
protected org.quartz.Scheduler |
scheduler |
| Modifier | Constructor and Description |
|---|---|
protected |
ExecutionSchedulerImpl(Configuration configuration)
Constructor used for unit testing
|
|
ExecutionSchedulerImpl(com.google.inject.Injector injector) |
| Modifier and Type | Method and Description |
|---|---|
void |
addJob(org.quartz.JobDetail jobDetail)
Persist job data
|
void |
deleteJob(org.quartz.JobKey jobKey)
Delete the identified Job from the Scheduler - and any associated Triggers.
|
org.quartz.JobDetail |
getJobDetail(org.quartz.JobKey jobKey)
Get details for a job from scheduler.
|
protected String[] |
getQuartzDbDelegateClassAndValidationQuery() |
protected Properties |
getQuartzSchedulerProperties() |
List<? extends org.quartz.Trigger> |
getTriggersForJob(org.quartz.JobKey jobKey)
Get all triggers created for a job.
|
protected void |
initializeScheduler() |
protected boolean |
isInitialized() |
boolean |
isSchedulerStarted()
Check whether the scheduler is already running.
|
void |
scheduleJob(org.quartz.Trigger trigger)
Add a trigger to the execution scheduler
|
void |
startScheduler(Integer delay)
Initialize and start the scheduler to accept jobs.
|
void |
stopScheduler()
Shutdown the scheduler threads and do not accept any more jobs.
|
protected static final String DEFAULT_SCHEDULER_NAME
protected org.quartz.Scheduler scheduler
protected static volatile boolean isInitialized
@Inject public ExecutionSchedulerImpl(com.google.inject.Injector injector)
protected ExecutionSchedulerImpl(Configuration configuration)
configuration - protected void initializeScheduler()
protected Properties getQuartzSchedulerProperties()
protected boolean isInitialized()
protected String[] getQuartzDbDelegateClassAndValidationQuery()
public void startScheduler(Integer delay) throws org.apache.ambari.server.AmbariException
ExecutionSchedulerstartScheduler in interface ExecutionSchedulerorg.apache.ambari.server.AmbariExceptionpublic void stopScheduler()
throws org.apache.ambari.server.AmbariException
ExecutionSchedulerstopScheduler in interface ExecutionSchedulerorg.apache.ambari.server.AmbariExceptionpublic void scheduleJob(org.quartz.Trigger trigger)
throws org.quartz.SchedulerException
ExecutionSchedulerscheduleJob in interface ExecutionSchedulerorg.quartz.SchedulerExceptionpublic void addJob(org.quartz.JobDetail jobDetail)
throws org.quartz.SchedulerException
ExecutionScheduleraddJob in interface ExecutionSchedulerorg.quartz.SchedulerExceptionpublic void deleteJob(org.quartz.JobKey jobKey)
throws org.quartz.SchedulerException
ExecutionSchedulerdeleteJob in interface ExecutionSchedulerorg.quartz.SchedulerExceptionpublic org.quartz.JobDetail getJobDetail(org.quartz.JobKey jobKey)
throws org.quartz.SchedulerException
ExecutionSchedulergetJobDetail in interface ExecutionSchedulerorg.quartz.SchedulerExceptionpublic List<? extends org.quartz.Trigger> getTriggersForJob(org.quartz.JobKey jobKey) throws org.quartz.SchedulerException
ExecutionSchedulergetTriggersForJob in interface ExecutionSchedulerorg.quartz.SchedulerExceptionpublic boolean isSchedulerStarted()
throws org.quartz.SchedulerException
ExecutionSchedulerisSchedulerStarted in interface ExecutionSchedulerorg.quartz.SchedulerExceptionCopyright © 2022 Apache Software Foundation. All rights reserved.