public class SmartExecutorScheduler extends Object
| Modifier and Type | Field and Description |
|---|---|
protected Set<UUID> |
scheduledJobs |
protected org.quartz.Scheduler |
scheduler |
| Modifier and Type | Method and Description |
|---|---|
protected org.quartz.TriggerBuilder<? extends org.quartz.Trigger> |
createTriggerBuilder(UUID uuid,
org.quartz.ScheduleBuilder<? extends org.quartz.Trigger> sb) |
protected List<org.quartz.JobExecutionContext> |
getCurrentlyExecutingJobs(org.quartz.Scheduler scheduler) |
org.gcube.vremanagement.executor.api.types.LaunchParameter |
getLaunchParameter(org.quartz.JobKey jobKey) |
protected org.quartz.TriggerBuilder<? extends org.quartz.Trigger> |
getTriggerBuilderWithScheduling(UUID uuid,
org.gcube.vremanagement.executor.api.types.Scheduling scheduling) |
protected void |
reallySchedule(UUID uuid,
org.gcube.vremanagement.executor.api.types.LaunchParameter parameter)
Create the Scheduler using the strategy provided by LaunchParameter
|
UUID |
schedule(org.gcube.vremanagement.executor.api.types.LaunchParameter parameter,
UUID uuid)
Schedule a task execution
|
void |
stop(UUID uuid,
boolean remove)
Stop the execution of the Task identified by UUID
|
void |
stopAll() |
protected void |
stopTask(UUID uuid) |
protected org.quartz.TriggerBuilder<? extends org.quartz.Trigger> createTriggerBuilder(UUID uuid, org.quartz.ScheduleBuilder<? extends org.quartz.Trigger> sb)
protected org.quartz.TriggerBuilder<? extends org.quartz.Trigger> getTriggerBuilderWithScheduling(UUID uuid, org.gcube.vremanagement.executor.api.types.Scheduling scheduling) throws org.gcube.vremanagement.executor.exception.LaunchException
org.gcube.vremanagement.executor.exception.LaunchExceptionprotected void reallySchedule(UUID uuid, org.gcube.vremanagement.executor.api.types.LaunchParameter parameter) throws org.gcube.vremanagement.executor.exception.LaunchException, org.quartz.SchedulerException
uuid - the UUID will be used to identify the taskparameter - LaunchParameter requested in service invocationorg.gcube.vremanagement.executor.exception.LaunchException - if the LaunchParameter does not contains a valid
scheduling strategyorg.quartz.SchedulerException - if the scheduler cannot be created by the
scheduler factorypublic UUID schedule(org.gcube.vremanagement.executor.api.types.LaunchParameter parameter, UUID uuid) throws org.gcube.vremanagement.executor.exception.InputsNullException, org.gcube.vremanagement.executor.exception.PluginNotFoundException, org.gcube.vremanagement.executor.exception.LaunchException
parameter - LaunchParameter requested in service invocationorg.gcube.vremanagement.executor.exception.LaunchException - if the LaunchParameter does not contains a valid
scheduling strategyorg.gcube.vremanagement.executor.exception.InputsNullException - if provided input map is nullorg.gcube.vremanagement.executor.exception.PluginNotFoundException - if the request plugin is not available on
this smart executor instanceprotected void stopTask(UUID uuid) throws org.gcube.vremanagement.executor.exception.UnableToInterruptTaskException
org.gcube.vremanagement.executor.exception.UnableToInterruptTaskExceptionprotected List<org.quartz.JobExecutionContext> getCurrentlyExecutingJobs(org.quartz.Scheduler scheduler) throws org.quartz.SchedulerException
org.quartz.SchedulerExceptionpublic org.gcube.vremanagement.executor.api.types.LaunchParameter getLaunchParameter(org.quartz.JobKey jobKey)
throws org.quartz.SchedulerException
org.quartz.SchedulerExceptionpublic void stop(UUID uuid, boolean remove) throws Exception
uuid - which identify the Taskremove - : when the Task is a Scheduled one indicate if the Task
has to be released or to be removed (the argument is set to true when
an explicit request arrive to remove the scheduled task)ExceptionSchedulerNotFoundExceptionpublic void stopAll()
throws org.quartz.SchedulerException
org.quartz.SchedulerExceptionCopyright © 2018. All Rights Reserved.