Cron expression

Cron expression string can be configured to automatically start a workflow every second, minute, hour, day, week or month.

The string has six single space-separated time and date fields:

 ┌───────────── second (30-59)
 │ ┌───────────── minute (0 - 59)
 │ │ ┌───────────── hour (0 - 23)
 │ │ │ ┌───────────── day of the month (1 - 31)
 │ │ │ │ ┌───────────── month (1 - 12) (or JAN-DEC)
 │ │ │ │ │ ┌───────────── day of the week (0 - 7)
 │ │ │ │ │ │          (0 or 7 is Sunday, or MON-SUN)
 │ │ │ │ │ │
 * * * * * *

The following rules apply:

Example expressions:

Expression

Description

0 0 * * * *

the top of every hour of every day

*/30 * * * * *

every thirty seconds

0 0 8-10 * * *

8, 9 and 10 o'clock of every day

0 0 6,19 * * *

6:00 AM and 7:00 PM every day

0 0/30 8-10 * * *

8:00, 8:30, 9:00, 9:30, 10:00 and 10:30 every day

0 0 9-17 * * MON-FRI

on the hour nine-to-five weekdays

0 0 0 25 12 ?

every Christmas Day at midnight

0 0 0 L * *

last day of the month at midnight

0 0 0 L-3 * *

third-to-last day of the month at midnight

0 0 0 1W * *

first weekday of the month at midnight

0 0 0 LW * *

last weekday of the month at midnight

0 0 0 * * 5L

last Friday of the month at midnight

0 0 0 * * THUL

last Thursday of the month at midnight

0 0 0 ? * 5#2

the second Friday in the month at midnight

0 0 0 ? * MON#1

the first Monday in the month at midnight

The following macros are also supported:

Macro

Description

@yearly

to run once a year, i.e. 0 0 0 1 1 *

@annually

@monthly

to run once a month, i.e. 0 0 0 1 * *

@weekly

to run once a week, i.e. 0 0 0 * * 0

@daily

to run once a day, i.e. 0 0 0 * * *

@midnight

@hourly

to run once an hour, i.e. 0 0 * * * *