chronos 3.0.3 starts jobs instantly instead of running it on their scheduled time

671 views Asked by At

I am using chronos 3.0.3. When I deploy jobs, it starts running all the jobs instantly on mesos slaves. I want chronos to run only on jobs' scheduled times and not instantly.

How can I configure to prevent running jobs instantly ? If someone can provide any pointer as in where in the chronos code, it is scheduling to run immediately, that will also be a great help.

I have defined epsilon of just 30 minutes in all the jobs, but it does not help; and run all the jobs.

These are all scheduled jobs and not dependent jobs.

1

There are 1 answers

7
Rico On

Set the schedule field in your json job definition to run whenever you'd like to run. The format is ISO 8601. For example:

"schedule": "R/2018-09-13T02:00:00.000Z/PT24H",
  • R: Means repeat forever
  • 2018-09-13: Date when you want to start running from
  • 02:00:00.000Z: Time when you want to run your job
  • PT24H: Run every 24 hours.

More info here.

Updating the schedule field to say run in 2 days works for me:

Schedule

Hope it helps.