Difference between revisions of "Admin Schedule Aliases"
(Created page with "= Schedule Alises = Schedule aliases allow you to define shortcuts to cron or recurrence patterns, or sets of them. Patterns can be combined with the standard cron pattern de...") |
|||
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | + | '''As of Obsidian 5.0''' | |
Schedule aliases allow you to define shortcuts to cron or recurrence patterns, or sets of them. Patterns can be combined with the standard cron pattern delimiter '';''. You can include other aliases in an alias' pattern. | Schedule aliases allow you to define shortcuts to cron or recurrence patterns, or sets of them. Patterns can be combined with the standard cron pattern delimiter '';''. You can include other aliases in an alias' pattern. | ||
Aliases are represented by a designation starting with <code>@</code> and are associated with the pattern it will represent. Aliases can be updated and will immediately take effect on all jobs referencing the alias. Aliases can only be removed if they are not referenced in any jobs. | Aliases are represented by a designation starting with <code>@</code> and are associated with the pattern it will represent. Aliases can be updated and will immediately take effect on all jobs referencing the alias. Aliases can only be removed if they are not referenced in any jobs. | ||
+ | |||
+ | [[Image:Obsidian.5.0.0.ScheduleAliases.png]] | ||
To use an alias, simply specify the alias designator (e.g. @dailyNoon) as the schedule value where you would otherwise type out the full cron pattern. | To use an alias, simply specify the alias designator (e.g. @dailyNoon) as the schedule value where you would otherwise type out the full cron pattern. | ||
+ | |||
+ | [[Image:Obsidian.5.0.0.UsingScheduleAliases.png]] | ||
+ | |||
+ | === Schedule Alias Fragments === | ||
+ | |||
+ | '''As of Obsidian 5.1''' | ||
+ | |||
+ | Aliases can include fragments that can be resolved by the job editor. For example, if you wanted an alias that would run at 12:45 AM on days to be determined later, you could create an alias with a DATE and/or DAY fragment. | ||
+ | |||
+ | |||
+ | ''Alias'' <code>@customEarly</code> | ||
+ | ''Schedule'' <code>45 0 DATE * DAY *</code> | ||
+ | |||
+ | Could then be referenced by a job editor, providing resolution to the fragments: | ||
+ | <code>@customEarly DATE:* DAY:1</code> to run at 12:45AM on all Mondays | ||
+ | <code>@customEarly DATE:1,15,20,25 DAY:*</code> to run at 12:45AM on 1st, 15th, 20th, 25th | ||
+ | |||
+ | |||
+ | [[Image:Obsidian.5.1.0.ScheduleAliasesFragments.png]] | ||
+ | [[Image:Obsidian.5.1.0.UsingScheduleAliasesWithFragments.png]] |
Latest revision as of 15:35, 8 April 2023
As of Obsidian 5.0
Schedule aliases allow you to define shortcuts to cron or recurrence patterns, or sets of them. Patterns can be combined with the standard cron pattern delimiter ;. You can include other aliases in an alias' pattern.
Aliases are represented by a designation starting with @
and are associated with the pattern it will represent. Aliases can be updated and will immediately take effect on all jobs referencing the alias. Aliases can only be removed if they are not referenced in any jobs.
To use an alias, simply specify the alias designator (e.g. @dailyNoon) as the schedule value where you would otherwise type out the full cron pattern.
Schedule Alias Fragments
As of Obsidian 5.1
Aliases can include fragments that can be resolved by the job editor. For example, if you wanted an alias that would run at 12:45 AM on days to be determined later, you could create an alias with a DATE and/or DAY fragment.
Alias @customEarly
Schedule 45 0 DATE * DAY *
Could then be referenced by a job editor, providing resolution to the fragments:
@customEarly DATE:* DAY:1
to run at 12:45AM on all Mondays
@customEarly DATE:1,15,20,25 DAY:*
to run at 12:45AM on 1st, 15th, 20th, 25th