Is your feature request related to a problem? Please describe
In some instances I would like to schedule future jobs to be run at specific times. Those could be totally or only partially in the future (in case of an engine restart in the middle of the schedule). For convenience reasons, it can be way easier to define an AtTimes job rather than a dedicated cron-schedule if the input from another system is a limited list of times.
Describe the solution you'd like
a new type of job that can be invoked similarly to the other, something like:
// OneTimeJob is to run a job once at a specified time and not on
// any regular schedule.
func AtTimesTimeJob(atTimes ...time.Time) JobDefinition
Describe alternatives you've considered
Multiple schedules with OneTimeJob is an alternative to the above. I find it less convenient and worse case the AtTimes should be a more generic way to implement also the OneTimeJob.
Is your feature request related to a problem? Please describe
In some instances I would like to schedule future jobs to be run at specific times. Those could be totally or only partially in the future (in case of an engine restart in the middle of the schedule). For convenience reasons, it can be way easier to define an
AtTimes
job rather than a dedicated cron-schedule if the input from another system is a limited list of times.Describe the solution you'd like
a new type of job that can be invoked similarly to the other, something like:
Describe alternatives you've considered
Multiple schedules with
OneTimeJob
is an alternative to the above. I find it less convenient and worse case theAtTimes
should be a more generic way to implement also theOneTimeJob
.Additional context