Job Scheduler
Allow users to schedule regular and repetitive jobs.
Features
Job: It has all the features that Job Submission has.
Recurrence: Allow to set Inactive, Daily, Weekly, Monthly, Custom Cron Format.
Run Manually: Allow to run scheduled jobs manually.
Configuration
Please add this variable to the .env
file.
Name | Value |
---|---|
|
|
Design
Custom Resource
A custom resource PhSchedule
is defined for PrimeHub-defined scheduled job. It utilizes the PrimeHub-defined job. It will submit a job regularly based on recurrence settings and job settings.
Here is an example of PhSchedule
.
Recurrence
Inactive
Every Day (at 4:00am)
Every Week (Sundays at 4:00am)
Every Month (on the 1st at 4:00am)
Custom: needs an additional cron field.
Invalid State
When a schedule contains a non-existing user/group/instancetype/image or the custom cron format is wrong, it would be marked as an invalid schedule.
Timezone
The timezone depends on the system timezone setting. If the system timezone changes, the schedule's cron setting would not change. However, the next run time would change because of timezone change.
The controller reconciles every 10mins so that the timezone setting would reflect in 10 mins.
Job Concurrency
When a schedule is triggered, it will not spawn a new job if the previous job is still running.
If a job is manually run against the schedule, it can run multiple jobs. And the scheduled job will also run no matter the manually ran job is completed or not. Because the manually spawned job is not associated with the schedule.
Job Label
If a job is spawned by the job scheduler, it will have a label:
Last updated