public interface ScheduledJobManager
Generally a ManagedScheduleJobException
is thrown if the input is invalid (e.g. job does not exist) or
if the type of request is not permitted (e.g. execute runNow when the job is not set to canRunAdhoc).
Modifier and Type | Method and Description |
---|---|
void |
disable(ScheduledJobKey key)
Disables the specified job, and removes it from the scheduler.
|
void |
enable(ScheduledJobKey key)
Enables the specified job, and adds it to the scheduler.
|
String |
getCronExpression(ScheduledJobKey key)
Gets the currently configured cron expression, or the default value if none has been configured.
|
Long |
getRepeatInterval(ScheduledJobKey key)
Gets the currently configured repeat interval, or the default value if none has been configured.
|
ScheduledJobStatus |
getScheduledJob(ScheduledJobKey key)
Gets the current status for a single scheduled job.
|
List<ScheduledJobStatus> |
getScheduledJobs()
Gets the list of managed job status.
|
void |
runNow(ScheduledJobKey key)
Schedules the specified to run immediately.
|
Date |
updateCronJobSchedule(ScheduledJobKey key,
String newCronSchedule)
Updates stored schedule.
|
Date |
updateSimpleJobSchedule(ScheduledJobKey key,
long repeatInterval)
Updates stored schedule.
|
List<ScheduledJobStatus> getScheduledJobs()
ScheduledJobStatus getScheduledJob(ScheduledJobKey key)
Date updateCronJobSchedule(ScheduledJobKey key, String newCronSchedule)
ManagedScheduledCronJob
and requires
AbstractManagedScheduledJob.isEditable()
to be true.Date updateSimpleJobSchedule(ScheduledJobKey key, long repeatInterval)
ManagedScheduledSimpleJob
and requires
AbstractManagedScheduledJob.isEditable()
to be true.void runNow(ScheduledJobKey key)
Requires ManagedScheduledJob.canRunAdhoc()
to be true.
void disable(ScheduledJobKey key)
Requires ManagedScheduledJob.canDisable()
to be true.
void enable(ScheduledJobKey key)
Requires ManagedScheduledJob.canDisable()
to be true.
String getCronExpression(ScheduledJobKey key)
null
if not a cron job.Long getRepeatInterval(ScheduledJobKey key)
null
if not a simple jobCopyright © 2003–2016 Atlassian. All rights reserved.