@ProviderType
public interface ScheduleOptions
Modifier and Type | Method and Description |
---|---|
ScheduleOptions |
canRunConcurrently(boolean flag)
Flag indicating whether the job can be run concurrently.
|
ScheduleOptions |
config(Map<String,Serializable> config)
Add optional configuration for the job.
|
ScheduleOptions |
name(String name)
Sets the name of the job.
|
ScheduleOptions |
onInstancesOnly(String[] slingIds)
List of Sling IDs this job should be run on.
|
ScheduleOptions |
onLeaderOnly(boolean flag)
Flag indicating whether the job should only be run on the leader.
|
ScheduleOptions |
onSingleInstanceOnly(boolean flag)
Flag indicating whether the job should only be run on a single instance in a cluster
This defaults to false.
|
ScheduleOptions config(Map<String,Serializable> config)
config
- An optional configuration object - this configuration is only passed to the job the job implements Job
.ScheduleOptions name(String name)
name
- The job nameScheduleOptions canRunConcurrently(boolean flag)
flag
- Whether this job can run even if previous scheduled runs are still running.ScheduleOptions onLeaderOnly(boolean flag)
onSingleInstanceOnly(boolean)
or onInstancesOnly(String[])
has been called before,
that option is reset and overwritten by the value of this method.flag
- Whether this job should only be run on the leaderScheduleOptions onSingleInstanceOnly(boolean flag)
onLeaderOnly(boolean)
or onInstancesOnly(String[])
has been called before,
that option is reset and overwritten by the value of this method.flag
- Whether this job should only be run on a single instance.ScheduleOptions onInstancesOnly(String[] slingIds)
onLeaderOnly(boolean)
or onSingleInstanceOnly(boolean)
has been called before,
that option is reset and overwritten by the value of this method.slingIds
- Array of Sling IDs this job should run onCopyright © 2014 The Apache Software Foundation. All rights reserved.