Search code examples
javacronquartz-schedulercronexpression

Cron job syntax for Quartz Jobs


I want a cron job running within my Quartz job scheduler running at 00:01 every day.

What is the cron expression for that?


Solution

  • This should do the trick:

    0 1 0 1/1 * ? *
    

    Explanation:

    The first value (0 in this case) is the seconds, the second value (1) is the minutes, the third value is the hours (0 for 12 am), the fourth value is the day of the month (1/1 means everyday), the fifth value is the month (* means all months), the sixth value is the day of the week (? means no specific value), the seventh value is the year (again * means every year).