Friday, March 17, 2017

Azure Functions timer = Unix cron++ (crontab)

Azure Functions timer trigger | Microsoft Docs
{second} {minute} {hour} {day} {month} {day-of-week}
To trigger once every five minutes:
"schedule": "0 */5 * * * *"
To trigger once at the top of every hour:
"schedule": "0 0 * * * *",
Azure Functions Overview | Microsoft Docs

crontab.guru - the cron schedule expression editor

Cron - Wikipedia
 ┌───────────── minute (0 - 59)
 │ ┌───────────── hour (0 - 23)
 │ │ ┌───────────── day of month (1 - 31)
 │ │ │ ┌───────────── month (1 - 12)
 │ │ │ │ ┌───────────── day of week (0 - 6) (Sunday to Saturday;
 │ │ │ │ │                                       7 is also Sunday)
 │ │ │ │ │
 │ │ │ │ │
 * * * * *  command to execute

Azure Functions have 6 position, added position for seconds in front of minutes.

crontab.org - CRONTAB(5)

No comments: