Class CronJobSpec
- java.lang.Object
-
- io.fabric8.kubernetes.api.model.batch.v1beta1.CronJobSpec
-
- All Implemented Interfaces:
io.fabric8.kubernetes.api.builder.Editable<CronJobSpecBuilder>,io.fabric8.kubernetes.api.model.KubernetesResource,Serializable
@Generated("io.fabric8.kubernetes.schema.generator.model.ModelGenerator") public class CronJobSpec extends Object implements io.fabric8.kubernetes.api.builder.Editable<CronJobSpecBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource
CronJobSpec describes how the job execution will look like and when it will actually run.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CronJobSpec()No args constructor for use in serializationCronJobSpec(String concurrencyPolicy, Integer failedJobsHistoryLimit, JobTemplateSpec jobTemplate, String schedule, Long startingDeadlineSeconds, Integer successfulJobsHistoryLimit, Boolean suspend)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CronJobSpecBuilderedit()Map<String,Object>getAdditionalProperties()StringgetConcurrencyPolicy()Specifies how to treat concurrent executions of a Job.IntegergetFailedJobsHistoryLimit()The number of failed finished jobs to retain.JobTemplateSpecgetJobTemplate()CronJobSpec describes how the job execution will look like and when it will actually run.StringgetSchedule()The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron.LonggetStartingDeadlineSeconds()Optional deadline in seconds for starting the job if it misses scheduled time for any reason.IntegergetSuccessfulJobsHistoryLimit()The number of successful finished jobs to retain.BooleangetSuspend()This flag tells the controller to suspend subsequent executions, it does not apply to already started executions.voidsetAdditionalProperties(Map<String,Object> additionalProperties)voidsetAdditionalProperty(String name, Object value)voidsetConcurrencyPolicy(String concurrencyPolicy)Specifies how to treat concurrent executions of a Job.voidsetFailedJobsHistoryLimit(Integer failedJobsHistoryLimit)The number of failed finished jobs to retain.voidsetJobTemplate(JobTemplateSpec jobTemplate)CronJobSpec describes how the job execution will look like and when it will actually run.voidsetSchedule(String schedule)The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron.voidsetStartingDeadlineSeconds(Long startingDeadlineSeconds)Optional deadline in seconds for starting the job if it misses scheduled time for any reason.voidsetSuccessfulJobsHistoryLimit(Integer successfulJobsHistoryLimit)The number of successful finished jobs to retain.voidsetSuspend(Boolean suspend)This flag tells the controller to suspend subsequent executions, it does not apply to already started executions.CronJobSpecBuildertoBuilder()
-
-
-
Method Detail
-
getConcurrencyPolicy
public String getConcurrencyPolicy()
Specifies how to treat concurrent executions of a Job. Valid values are: - "Allow" (default): allows CronJobs to run concurrently; - "Forbid": forbids concurrent runs, skipping next run if previous run hasn't finished yet; - "Replace": cancels currently running job and replaces it with a new one
-
setConcurrencyPolicy
public void setConcurrencyPolicy(String concurrencyPolicy)
Specifies how to treat concurrent executions of a Job. Valid values are: - "Allow" (default): allows CronJobs to run concurrently; - "Forbid": forbids concurrent runs, skipping next run if previous run hasn't finished yet; - "Replace": cancels currently running job and replaces it with a new one
-
getFailedJobsHistoryLimit
public Integer getFailedJobsHistoryLimit()
The number of failed finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1.
-
setFailedJobsHistoryLimit
public void setFailedJobsHistoryLimit(Integer failedJobsHistoryLimit)
The number of failed finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1.
-
getJobTemplate
public JobTemplateSpec getJobTemplate()
CronJobSpec describes how the job execution will look like and when it will actually run.
-
setJobTemplate
public void setJobTemplate(JobTemplateSpec jobTemplate)
CronJobSpec describes how the job execution will look like and when it will actually run.
-
getSchedule
public String getSchedule()
The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron.
-
setSchedule
public void setSchedule(String schedule)
The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron.
-
getStartingDeadlineSeconds
public Long getStartingDeadlineSeconds()
Optional deadline in seconds for starting the job if it misses scheduled time for any reason. Missed jobs executions will be counted as failed ones.
-
setStartingDeadlineSeconds
public void setStartingDeadlineSeconds(Long startingDeadlineSeconds)
Optional deadline in seconds for starting the job if it misses scheduled time for any reason. Missed jobs executions will be counted as failed ones.
-
getSuccessfulJobsHistoryLimit
public Integer getSuccessfulJobsHistoryLimit()
The number of successful finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. Defaults to 3.
-
setSuccessfulJobsHistoryLimit
public void setSuccessfulJobsHistoryLimit(Integer successfulJobsHistoryLimit)
The number of successful finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. Defaults to 3.
-
getSuspend
public Boolean getSuspend()
This flag tells the controller to suspend subsequent executions, it does not apply to already started executions. Defaults to false.
-
setSuspend
public void setSuspend(Boolean suspend)
This flag tells the controller to suspend subsequent executions, it does not apply to already started executions. Defaults to false.
-
edit
public CronJobSpecBuilder edit()
- Specified by:
editin interfaceio.fabric8.kubernetes.api.builder.Editable<CronJobSpecBuilder>
-
toBuilder
public CronJobSpecBuilder toBuilder()
-
-