A schedule uses a CRON expression to determine how often source inputs are updated. Multiple sources can be assigned to a single schedule.
Schedules
Schedules can be accessed from the main menu; simply hit Schedules to be taken to the list of Schedules.
The schedule description is always the parsed CRON expression. Names can be anything, but best practice is to have a CRON expression present or use time specific statement.
WARNING: Be sure to set the schedule to a valid cron to avoid issues with the DataForge platform. For example, avoid setting the cron schedule to run the 31st of every month since not every month has a 31st date.
Schedule Settings
The schedule settings page allows users to create and update schedules. The example below will run every hour of the day at 41, 42, 43, and 45 minutes past the hour. All schedules represent UTC times.
- Name*: A unique name. Best practice has a CRON expression present.
- Seconds: Number of seconds ranging from 0-59 - Allowed Special Characters: , - *
- Minutes: Number of minutes ranging from 0-59 - Allowed Special Characters: , - *
- Hours: Number of hours ranging from 0-23 - Allowed Special Characters: , - *
- Day of Month: Specific days of the month as numerals ranging from 1-31 - Allowed Special Characters: , - * ? L W C
- Month: Specific months using 1-12 or JAN-DEC - Allowed Special Characters: , - *
- Day of Week: Specific days of the week as numerals ranging from 0-6 (0=Monday 6=Sunday) - Allowed Special Characters: , - * ? L C #
- Error Retry Count*: Number of times the input will retry upon error (default 3)
- Error Retry Wait*: Number of seconds the input will wait before retry (default 60)
Add a Schedule to a Source
In order to add a schedule to a source, simply navigate to the source settings page of your desired source. There, select the desired schedule from the Schedules dropdown. The dropdown is located directly beneath the Initiation Type.
The schedules dropdown will not appear for loopback connections or watcher initiation types.
If disable initiation is set to true in the Ingestion settings, the schedule will not run.
CRON Expressions
CRON (Command Run On) is used to create repetitive schedules. Use the following rules to create a CRON expression:
Field |
Allowed Values
|
Allowed Special Characters |
Seconds | 0-59 | , - * |
Minutes | 0-59 | , - * |
Hours | 0-23 | , - * |
Day of month | 1-31 | , - * ? L W |
Month | 1-12 or JAN-DEC | , - * |
Day of week |
0-6 or MON-SUN
|
, - * ? L # |
You must specify either day of month or day of week, but not both. Insert a question mark (?) as a placeholder for the one not specified.
The names of months and days of the week are not case sensitive. "MON" is the same as "mon".
Using Special Characters
The following table describes the legal special characters and how you can use them in a CRON expression:
Special Character
|
Description
|
* (all values)
|
Selects all values within a field.
For example, * in the minute field selects "every minute".
|
? (no specific value)
|
Used to specify something in one of the two fields in which the character is allowed, but not the other.
For example, to make the trigger fire on a particular day of the month (say, the 10th), when it does not matter what day of the week that happens to be, put
10 in the day-of-month field, and ? in the day-of-week field. |
- (range)
|
Used to specify ranges.
For example,
10-12 in the hour field selects the hours 10, 11 and 12. |
, (comma)
|
Used to specify additional values.
For example,
MON,WED,FRI in the day-of-week field means the days Monday, Wednesday, and Friday. |
L (last)
|
Used differently in each of the two fields in which it is allowed:
When using the
L special character, do not specify lists, or ranges of values, because this may give confusing results. |
W (weekday)
|
Used to specify the weekday (Monday-Friday) nearest to the given day.
For example, if you specify
15W as the value for the day-of-month field, the nearest weekday to the 15th of the month is selected. So if the 15th is a Saturday, Friday the 14th is selected. If the 15th is a Sunday, Monday the 16th is selected. If the 15th is a Tuesday, Tuesday the 15th is selected.However if you specify
1W as the value for day-of-month, and the 1st is a Saturday, Monday the 3rd is selected, as the selection rules do not allow for crossing over the boundary of a month's days to the previous or the subsequent month.The
W character can only be used to specify a single day, not a range or list of days. |
C (calendar)
|
This character is short-hand for "calendar" and is only allowed for the day-of-month and day-of-week fields. This means values are calculated against the associated calendar, if any. If no calendar is associated, then it is equivalent to having an all-inclusive calendar. A value of "5C" in the day-of-month field means "the first day included by the calendar on or after the 5th." A value of "1C" in the day-of-week field means "the first day included by the calendar on or after Tuesday" |
# |
Used to specify the nth XXX (or XX) day of the month.
For example, the value
FRI#3 or 6#3 in the day-of-week field means the third Friday of the month (6 or FRI = Friday, and #3 = the 3rd one in the month). |
TheL
andW
characters can also be combined in the day-of-month field to yieldLW
, which translates to "last weekday of the month".
Example Schedules
Every Hour
0 0 * * * ?
Every 30 Minutes
0 1,31 * * * ?
Once per Week - Every Monday
0 0 12 ? * 0
Once per Month - Every 1st of the Month
0 0 12 1 * ?
When specifying days of the month to run, be sure that the days will exist in every month designated to run to avoid issues. For example, do not set the schedule to run on the 31st of every month.
Updated