rfc9922.original.md   rfc9922.md 
--- ---
title: "A Common YANG Data Model for Scheduling" title: "A Common YANG Data Model for Scheduling"
abbrev: "Common Schedule YANG" abbrev: "YANG Scheduling"
category: std category: std
ipr: trust200902
docname: draft-ietf-netmod-schedule-yang-rfceditor-latest docname: draft-ietf-netmod-schedule-yang-rfceditor-latest
submissiontype: IETF submissiontype: IETF
number: number: 9922
date: date: 2026-02
consensus: true consensus: true
v: 3 v: 3
area: "Operations and Management" lang: en
pi: [toc, symrefs, sortrefs]
area: "OPS"
workgroup: "netmod" workgroup: "netmod"
keyword: keyword:
- calendaring - calendaring
- scheduling - scheduling
- YANG - YANG
- groupings - groupings
author: author:
- -
fullname: Qiufang Ma fullname: Qiufang Ma
skipping to change at line 53 skipping to change at line 55
code: 35000 code: 35000
country: France country: France
email: mohamed.boucadair@orange.com email: mohamed.boucadair@orange.com
- -
fullname: Daniel King fullname: Daniel King
organization: Lancaster University organization: Lancaster University
country: United Kingdom country: United Kingdom
email: d.king@lancaster.ac.uk email: d.king@lancaster.ac.uk
normative: normative:
W3C.XML1.0:
target: https://www.w3.org/TR/2008/REC-xml-20081126/
title: "Extensible Markup Language (XML) 1.0 (Fifth Edition)"
date: 2008-11-26
author:
- name: Tim Bray
role: editor
- name: Jean Paoli
role: editor
- name: C. M. Sperberg-McQueen
role: editor
- name: Eve Maler
role: editor
- name: Francois Yergeau
role: editor
rc:
W3C Recommendation
informative: informative:
I-D.ietf-netmod-eca-policy:
display: NETMOD-ECA-POLICY
I-D.ietf-netmod-rfc8407bis:
display: YANG-GUIDE
I-D.ietf-ntp-ntpv5:
display: NTPv5
I-D.ietf-opsawg-scheduling-oam-tests:
display: YANG-OAM
I-D.ietf-opsawg-ucl-acl:
display: YANG-NAC
I-D.ietf-tvr-schedule-yang:
display: YANG-SCHEDULE
I-D.liu-netmod-yang-schedule:
display: YANG-CONFIG-SCHEDULE
--- abstract --- abstract
<!-- [rfced] FYI - We will do the following when we convert the file to RFCXML:
- compact the spacing of the definition lists in Sections 8.1 and 8.2
-->
<!--[rfced] Note that we have updated the short title, which appears in the
running header in the PDF output, as follows. Please let us know of any
objections.
Original:
Common Schedule YANG
Current:
YANG Scheduling
-->
This document defines common types and groupings that are meant to be used This document defines common types and groupings that are meant to be used
for scheduling purposes such as event, policy, services, or resources based on for scheduling purposes, such as events, policies, services, or resources based on
date and time. For the sake of better modularity, the YANG module includes a date and time. For the sake of better modularity, the YANG module includes a
set of recurrence-related groupings with varying levels of representation set of recurrence-related groupings with varying levels of representation
(i.e., from basic to advanced) to accommodate a variety of requirements. (i.e., from basic to advanced) to accommodate a variety of requirements.
It also defines groupings for validating requested schedules and reporting schedul ing status. It also defines groupings for validating requested schedules and reporting schedul ing statuses.
--- middle --- middle
# Introduction {#intro} # Introduction {#intro}
This document defines a common schedule YANG module ("ietf-schedule") that can This document defines a common schedule YANG module ("ietf-schedule") that can
be used in several scheduling contexts, e.g., (but not limited to) be used in several scheduling contexts, e.g., (but not limited to)
{{?I-D.ietf-opsawg-ucl-acl}}, {{?I-D.ietf-opsawg-scheduling-oam-tests}}, {{?I-D.ietf-opsawg-ucl-acl}}, {{?I-D.ietf-opsawg-scheduling-oam-tests}},
and {{?I-D.ietf-tvr-schedule-yang}}. The module includes a set of reusable groupings and {{?I-D.ietf-tvr-schedule-yang}}. The module includes a set of reusable groupings
which that
are designed to be applicable for scheduling purposes such as event, policy, are designed to be applicable for scheduling purposes, such as events, policies,
services or resources based on date and time. It also defines groupings for validatin services, or resources based on date and time. It also defines groupings for validati
g ng
requested schedules and reporting scheduling status. requested schedules and reporting scheduling statuses.
This document does not make any assumption about the nature of actions that are This document does not make any assumption about the nature of actions that are
triggered by the schedules. Detection and resolution of any schedule conflicts triggered by the schedules. Detection and resolution of any schedule conflicts
are beyond the scope of this document. are beyond the scope of this document.
<!--[rfced] To avoid awkward hyphenation, may we update this sentence to read as
"objects managed by MIB"?
Original:
Section 5 discusses the relationship with the Management Information
Base (MIB) managed objects for scheduling management operations
defined in [RFC3231].
Perhaps:
Section 5 discusses the relationship with the objects managed by
Management Information Base (MIB) for scheduling management operations
defined in [RFC3231].
-->
{{sec-mib}} discusses the relationship with the Management Information Base (MIB) {{sec-mib}} discusses the relationship with the Management Information Base (MIB)
managed objects for scheduling management operations defined in {{!RFC3231}}. managed objects for scheduling management operations defined in {{!RFC3231}}.
{{usage}} describes a set of examples to illustrate the use of the common schedule gr oupings ({{sec-grp}}). {{usage}} describes a set of examples to illustrate the use of the common schedule gr oupings ({{sec-grp}}).
{{sec-ext}} provides sample modules to exemplify how future modules can use the exten sibility {{sec-ext}} provides sample modules to exemplify how future modules can use the exten sibility
provisions in the "ietf-schedule" module ({{sec-schedule}}). Also, {{ex-framework}} p rovides provisions in the "ietf-schedule" module ({{sec-schedule}}). Also, {{ex-framework}} p rovides
an example of using the "ietf-schedule" module for scheduled use of a resources frame work (e.g., {{?RFC8413}}). an example of using the "ietf-schedule" module for scheduled use of a resources frame work (e.g., {{?RFC8413}}).
## Editorial Note (To be removed by RFC Editor)
Note to the RFC Editor: This section is to be removed prior to publication.
This document contains placeholder values that need to be replaced with finalized
values at the time of publication. This note summarizes all of the
substitutions that are needed. No other RFC Editor instructions are specified
elsewhere in this document.
Please apply the following replacements:
* XXXX --> the assigned RFC number for this draft
* 2025-05-30 --> the actual date of the publication of this document
# Conventions and Definitions # Conventions and Definitions
{::boilerplate bcp14-tagged} {::boilerplate bcp14-tagged}
The meanings of the symbols in tree diagrams are defined in The meanings of the symbols in tree diagrams are defined in
{{?RFC8340}}. {{?RFC8340}}.
This document uses the YANG terminology defined in {{Section 3 of !RFC7950}}. This document uses the YANG terminology defined in {{Section 3 of !RFC7950}}.
The document makes use of the following terms: This document makes use of the following terms:
Recurrence rule: Recurrence rule:
: Refers to a rule or repeating pattern for recurring events. See also {{Section 3.8. 5.3 of !RFC5545}} for a comprehensive iCalendar recurrence rule specification. : Refers to a rule or repeating pattern for recurring events. See also {{Section 3.8. 5.3 of !RFC5545}} for a comprehensive iCalendar recurrence rule specification.
Recurrence instance (or Recurrence, for short): Recurrence instance (or Recurrence, for short):
: Refers to an instance that matches a recurrence rule. : Refers to an instance that matches a recurrence rule.
Recurrence set: Recurrence set:
: Refers to a set of recurrence instances. : Refers to a set of recurrence instances.
Frequency: Frequency:
: Characterizes the type of a recurrence rule. Values are taken from "FREQ" rule in { {Section 3.3.10 of !RFC5545}}. : Characterizes the type of a recurrence rule. Values are taken from the "FREQ" rule in {{Section 3.3.10 of !RFC5545}}.
: For example, repeating events based on an interval of a second or more are : For example, repeating events based on an interval of a second or more are
classified as recurrence with a frequency value of "SECONDLY". Frequency values def ined as identities classified as recurrence with a frequency value of "SECONDLY". Frequency values def ined as identities
in the YANG module are used in lowercase. in the YANG module are used in lowercase.
iCalendar: iCalendar:
: Refers to Internet Calendaring per {{!RFC5545}}. : Refers to Internet Calendaring per {{!RFC5545}}.
Interval: Interval:
: Refers to an integer that specifies interval at which a recurrence rule repeats. Va : Refers to an integer that specifies the interval at which a recurrence rule repeats
lues are taken from "INTERVAL" rule in {{Section 3.3.10 of !RFC5545}}. . Values are taken from the "INTERVAL" rule in {{Section 3.3.10 of !RFC5545}}.
: For example, "1", means every second for a secondly rule, every minute for a minute : For example, "1" means every second for a secondly rule, every minute for a minutel
ly rule, every hour for an hourly rule, etc. y rule, every hour for an hourly rule, etc.
System: System:
: Refers to an entity that hosts a schedule that is managed using the YANG module def ined in this document. : Refers to an entity that hosts a schedule that is managed using the YANG module def ined in this document.
# Module Overview {#sec-overview} # Module Overview {#sec-overview}
## Features {#sec-features} ## Features {#sec-features}
The "ietf-schedule" data model defines the recurrence related groupings using The "ietf-schedule" data model defines the recurrence-related groupings using
a modular approach. To that aim, a variety of representations of recurrence a modular approach. To that aim, a variety of representations of recurrence
groupings ranging from basic to advanced (iCalender-like) are defined. groupings ranging from basic to advanced (iCalender-like) are defined.
To allow for different options, two features are defined in the data model: To allow for different options, two features are defined in the data model:
* "basic-recurrence" * "basic-recurrence"
* "icalendar-recurrence" * "icalendar-recurrence"
Refer to Sections {{<sec-aug}} and {{<features}} for the use of these features. Refer to {{sec-aug}} and {{features}} for the use of these features.
## Types and Identities {#sec-types} ## Types and Identities {#sec-types}
The "ietf-schedule" module ({{sec-schedule}}) defines the following identities: The "ietf-schedule" module ({{sec-schedule}}) defines the following identities:
* "schedule-type": Indicates the type of a schedule. The following types are defin * "schedule-type": Indicates the type of schedule. The following types are defined
ed so far: so far:
+ one-shot: The schedule will trigger an action that has either the duration sp + one-shot: The schedule will trigger an action that has either the duration sp
ecified as 0 or the end time specified the same as start time, and then the schedule ecified as 0 or the end time specified as the same as the start time, and then the sc
will disable itself ({{Section 3.3 of !RFC3231}}). hedule will disable itself ({{Section 3.3 of !RFC3231}}).
+ period: The schedule is a period-based schedule consisting either (1) a start + period: This type is used for a period-based schedule consisting of either (1
and end or (2) a start and positive duration of time. If neither an end nor a durati ) a start and end or (2) a start and positive duration of time. If neither an end nor
on is indicated, the period is considered to last forever. a duration is indicated, the period is considered to last forever.
+ recurrence: This type is used for a recurrence-based schedule. A recurrence m ay be periodic (i.e., repeat over the same period, e.g., every five minutes) or not ( i.e., repeat in a non-regular manner, e.g., every day at 8 and 9 AM). + recurrence: This type is used for a recurrence-based schedule. A recurrence m ay be periodic (i.e., repeat over the same period, e.g., every five minutes) or not ( i.e., repeat in a non-regular manner, e.g., every day at 8 and 9 AM).
* "frequency-type": Characterizes the repeating interval rule of a recurrence sche dule (secondly, minutely, etc.). * "frequency-type": Characterizes the repeating interval rule of a recurrence sche dule (secondly, minutely, etc.).
* "schedule-state": Indicates the status of a schedule (enabled, disabled, conflic ted, finished, etc.). This identity can also be used * "schedule-state": Indicates the status of a schedule (enabled, disabled, conflic ted, finished, etc.). This identity can also be used
to manage the state of individual instances of a recurrence-based schedule. to manage the state of individual instances of a recurrence-based schedule.
* "discard-action-type": Specifies the action for the responder to take (e.g., gen erate a warning or an error message) when * "discard-action-type": Specifies the action for the responder to take (e.g., gen erate a warning or an error message) when
a requested schedule cannot be accepted for any reason and is discarded. a requested schedule cannot be accepted for any reason and is discarded.
## Scheduling Groupings {#sec-grp} ## Scheduling Groupings {#sec-grp}
The "ietf-schedule" module ({{sec-schedule}}) defines the following groupings: The "ietf-schedule" module ({{sec-schedule}}) defines the following groupings:
skipping to change at line 186 skipping to change at line 241
* "recurrence-utc-with-periods" ({{sec-rec-utc-dt}}) * "recurrence-utc-with-periods" ({{sec-rec-utc-dt}})
* "recurrence-time-zone-with-periods" ({{sec-rec-tz-dt}}) * "recurrence-time-zone-with-periods" ({{sec-rec-tz-dt}})
* "icalendar-recurrence" ({{sec-ical-rec}}) * "icalendar-recurrence" ({{sec-ical-rec}})
* "schedule-status", "schedule-status-with-time-zone", and "schedule-status-with-n ame" ({{sec-schedule-status}}) * "schedule-status", "schedule-status-with-time-zone", and "schedule-status-with-n ame" ({{sec-schedule-status}})
Examples are provided in {{usage}}. Examples are provided in {{usage}}.
### The "generic-schedule-params" Grouping {#sec-gen} ### The "generic-schedule-params" Grouping {#sec-gen}
A system accepts and handles schedule requests, which may help further A system accepts and handles schedule requests, which may help further
automate the scheduling process of events, policy, services, or resources automate the scheduling process of events, policies, services, or resources
based on date and time. The "generic-schedule-params" grouping ({{gsp-tree}}) based on date and time. The "generic-schedule-params" grouping ({{gsp-tree}})
specifies a set of configuration parameters that are used by a system for specifies a set of configuration parameters that are used by a system for
validating requested schedules. validating requested schedules.
~~~~ ~~~~ yangtree
grouping generic-schedule-params: grouping generic-schedule-params:
+-- description? string +-- description? string
+-- time-zone-identifier? sys:timezone-name +-- time-zone-identifier? sys:timezone-name
+-- validity? yang:date-and-time +-- validity? yang:date-and-time
+-- max-allowed-start? yang:date-and-time +-- max-allowed-start? yang:date-and-time
+-- min-allowed-start? yang:date-and-time +-- min-allowed-start? yang:date-and-time
+-- max-allowed-end? yang:date-and-time +-- max-allowed-end? yang:date-and-time
+-- discard-action? identityref +-- discard-action? identityref
~~~~ ~~~~
{: #gsp-tree title="'generic-schedule-params' Tree Structure"} {: #gsp-tree title="'generic-schedule-params' Grouping Tree Structure"}
The "description" includes a description of the schedule. No constraint is imposed The "description" parameter includes a description of the schedule. No constraint is imposed
on the structure nor the use of this parameter. on the structure nor the use of this parameter.
The "time-zone-identifier" parameter, if provided, specifies the The "time-zone-identifier" parameter, if provided, specifies the
time zone reference {{!RFC7317}} of the local date and time values. This parameter time zone reference {{!RFC7317}} of the local date and time values. This parameter
MUST be specified if any of the date and time values are in the format of local ti me. MUST be specified if any of the date and time values are in the format of local ti me.
It MUST NOT be applied to date and time values which are specified in the format It MUST NOT be applied to date and time values that are specified in the format
of UTC or time zone offset to UTC. of UTC or time zone offset to UTC.
<!--[rfced] Please clarify "to execute independent of when it
ends". Is the meaning that the validity parameter determines when a
schedule can be started and thus "executed independently from when it
ends"?
Original:
It determines the latest time that a schedule can be started to
execute independent of when it ends and takes precedence over
similar attributes that are provided at the schedule instance
itself.
Perhaps:
It determines the latest time that a schedule can be started and
thus executed independently from when it ends, and it takes
precedence over similar attributes that are provided at the
schedule instance itself.
-->
The "validity" parameter specifies the date and time after which a schedule The "validity" parameter specifies the date and time after which a schedule
will not be considered as valid. It determines the latest time that a schedule will not be considered as valid. It determines the latest time that a schedule
can be started to execute independent of when it ends and takes precedence over can be started to execute independent of when it ends, and it takes precedence ove r
similar attributes that are provided at the schedule instance itself. A requested similar attributes that are provided at the schedule instance itself. A requested
schedule may still be accepted but any occurrences that start later than the confi gured value will not be executed. schedule may still be accepted, but any occurrences that start later than the conf igured value will not be executed.
The "max/min-allowed-start" parameters specify the maximum/minimum scheduled The "max/min-allowed-start" parameters specify the maximum/minimum scheduled
start date and time. A requested schedule will be rejected if the first start date and time. A requested schedule will be rejected if the first
occurrence of the schedule starts later/earlier than the configured values. occurrence of the schedule starts later/earlier than the configured values.
The "max-allowed-end" parameter specifies the maximum allowed end time of The "max-allowed-end" parameter specifies the maximum allowed end time of
the last occurrence. A requested schedule will be rejected if the end time the last occurrence. A requested schedule will be rejected if the end time
of last occurrence is later than the configured "max-allowed-end" value. of the last occurrence is later than the configured "max-allowed-end" value.
The "discard-action" parameter specifies the action if a requested schedule The "discard-action" parameter specifies the action if a requested schedule
cannot be accepted for any reason and is discarded. Possible reasons include, cannot be accepted for any reason and is discarded. Possible reasons include,
but are not limited to, the requested schedule failing to satisfy the guards in th is grouping, but are not limited to, the requested schedule failing to satisfy the guards in th is grouping,
conflicting with existing schedules, or being out-of-date (e.g., the expected star conflicting with existing schedules, or being out-of-date (e.g., the expected star
t is already passed). t has already passed).
<!--[rfced] May we update this sentence to make the two items
mentioned (i.e., "all schedules on a system" and "too short schedule
requests") more parallel and thus easier to read?
Original:
These parameters apply to all schedules on a system and are meant to
provide guards against stale configuration, too short schedule
requests that would prevent validation by admins of some critical
systems, etc.
Perhaps:
These parameters apply to all schedules on a system and are meant
to provide guards against stale configuration, schedule requests
that are too short and that would thus prevent validation by admins
of some critical systems, etc.
-->*
These parameters apply to all schedules on a system and are meant These parameters apply to all schedules on a system and are meant
to provide guards against stale configuration, too short schedule requests to provide guards against stale configuration, too short schedule requests
that would prevent validation by admins of some critical systems, etc. that would prevent validation by admins of some critical systems, etc.
### The "period-of-time" Grouping {#sec-period} ### The "period-of-time" Grouping {#sec-period}
The "period-of-time" grouping ({{pt-tree}}) represents a time period using The "period-of-time" grouping ({{pt-tree}}) represents a time period using
either a start date and time ("period-start") and end date and time ("period-end") , or a either a start date and time ("period-start") and end date and time ("period-end") or a
start date and time ("period-start") and a non-negative time duration ("duration") . For the first start date and time ("period-start") and a non-negative time duration ("duration") . For the first
format, the start of the period MUST be no later than the end of the period. If ne ither an end date and time ("period-end") format, the start of the period MUST be no later than the end of the period. If ne ither an end date and time ("period-end")
nor a duration ("duration") is indicated, the period is considered to last forever . nor a duration ("duration") is indicated, the period is considered to last forever .
If the duration ("duration") value is 0 or the end time ("period-end") is the same as the start time ("period-start"), the period If the duration ("duration") value is 0 or the end time ("period-end") is the same as the start time ("period-start"), the period
is considered as a one-shot schedule. If no start date and time ("period-start") is considered as a one-shot schedule. If no start date and time ("period-start")
is specified, the period is considered to start immediately. is specified, the period is considered to start immediately.
The "time-zone-identifier" parameter indicates the identifier for the The "time-zone-identifier" parameter indicates the identifier for the
time zone. This parameter MUST be specified if either the "period-start" or "perio d-end" time zone. This parameter MUST be specified if either the "period-start" or "perio d-end"
value is reported in local time format. It MUST NOT be applied to date and time value is reported in local time format. It MUST NOT be applied to date and time
values which are specified in the format of UTC or time zone offset to UTC. values that are specified in the format of UTC or time zone offset to UTC.
The "period-description" includes a description of the period. No constraint is im posed The "period-description" parameter includes a description of the period. No constr aint is imposed
on the structure nor the use of this parameter. on the structure nor the use of this parameter.
~~~~ ~~~~ yangtree
grouping period-of-time: grouping period-of-time:
+-- period-description? string +-- period-description? string
+-- period-start? yang:date-and-time +-- period-start? yang:date-and-time
+-- time-zone-identifier? sys:timezone-name +-- time-zone-identifier? sys:timezone-name
+-- (period-type)? +-- (period-type)?
+--:(explicit) +--:(explicit)
| +-- period-end? yang:date-and-time | +-- period-end? yang:date-and-time
+--:(duration) +--:(duration)
+-- duration? duration +-- duration? duration
~~~~ ~~~~
{: #pt-tree title="'period-of-time' Grouping Tree Structure"} {: #pt-tree title="'period-of-time' Grouping Tree Structure"}
### The "recurrence-basic" Grouping {#sec-rec} ### The "recurrence-basic" Grouping {#sec-rec}
The "recurrence-basic" grouping ({{rec-grp-tree}}) specifies a simple recurrence ru le which starts immediately and repeats forever. The "recurrence-basic" grouping ({{rec-grp-tree}}) specifies a simple recurrence ru le that starts immediately and repeats forever.
~~~~ ~~~~ yangtree
grouping recurrence-basic: grouping recurrence-basic:
+-- recurrence-description? string +-- recurrence-description? string
+-- frequency? identityref +-- frequency? identityref
+-- interval? uint32 +-- interval? uint32
~~~~ ~~~~
{: #rec-grp-tree title="'recurrence-basic' Grouping Tree Structure"} {: #rec-grp-tree title="'recurrence-basic' Grouping Tree Structure"}
The frequency parameter ("frequency") identifies the type of a recurrence rule. For example, The frequency parameter ("frequency") identifies the type of recurrence rule. For e xample,
a "daily" frequency value specifies repeating events based on an interval of a day or more. a "daily" frequency value specifies repeating events based on an interval of a day or more.
Consistent with {{Section 3.3.10 of !RFC5545}}, the interval ("interval") represent s at which interval the recurrence rule repeats. For example, Consistent with {{Section 3.3.10 of !RFC5545}}, the interval parameter ("interval") represents at which interval the recurrence rule repeats. For example,
within a "daily" recurrence rule, an interval value of "8" means every eight days. within a "daily" recurrence rule, an interval value of "8" means every eight days.
Note that per {{Section 4.13 of ?I-D.ietf-netmod-rfc8407bis}}, neither a "default" <!-- [rfced] We note that Section 4.13 of [I-D.ietf-netmod-rfc8407bis] mentions
"default" but doesn't mention "mandatory"; however, Section 4.14
mentions both "default" and "mandatory". Should the citations below be updated
to point to Section 4.14 instead?
Original (Section 3.3.3):
Note that per Section 4.13 of [I-D.ietf-netmod-rfc8407bis], neither a
"default" nor a "mandatory" substatement is defined here for both
"frequency" and "interval" parameters because there are cases (e.g.,
profiling) where using these statements is problematic.
Original (Section 3.3.8):
Note that per Section 4.13 of [I-D.ietf-netmod-rfc8407bis], neither a
"default" nor a "mandatory" substatement is defined here because there
are cases (e.g., profiling) where using these statements is problematic.
-->
Note that, per {{Section 4.13 of ?I-D.ietf-netmod-rfc8407bis}}, neither a "default"
nor a "mandatory" substatement is defined here for both "frequency" and "interval" nor a "mandatory" substatement is defined here for both "frequency" and "interval"
parameters because there are cases (e.g., profiling) where using these statements i s problematic. parameters because there are cases (e.g., profiling) where using these statements i s problematic.
YANG modules using this grouping SHOULD refine these two nodes with either a YANG modules using this grouping SHOULD refine these two nodes with either a
"mandatory" or a "default" statement, if they always need to be configured or have default values. "mandatory" or a "default" statement if they always need to be configured or have d efault values.
This recommendation MAY be ignored in cases such as when this grouping is used by a nother grouping. This recommendation MAY be ignored in cases such as when this grouping is used by a nother grouping.
The "recurrence-description" includes a description of the period. No constraint is imposed The "recurrence-description" parameter includes a description of the period. No con straint is imposed
on the structure nor the use of this parameter. on the structure nor the use of this parameter.
### The "recurrence-utc" Grouping {#sec-rec-utc} ### The "recurrence-utc" Grouping {#sec-rec-utc}
The "recurrence-utc" grouping ({{rec-utc-grp-tree}}) uses the "recurrence-basic" The "recurrence-utc" grouping ({{rec-utc-grp-tree}}) uses the "recurrence-basic"
grouping ({{sec-rec}}) and specifies a simple recurrence rule in UTC format. grouping ({{sec-rec}}) and specifies a simple recurrence rule in UTC format.
~~~~ ~~~~ yangtree
grouping recurrence-utc: grouping recurrence-utc:
+-- recurrence-first +-- recurrence-first
| +-- start-time-utc? yang:date-and-time | +-- start-time-utc? yang:date-and-time
| +-- duration? uint32 | +-- duration? uint32
+-- (recurrence-end)? +-- (recurrence-end)?
| +--:(until) | +--:(until)
| | +-- utc-until? yang:date-and-time | | +-- utc-until? yang:date-and-time
| +--:(count) | +--:(count)
| +-- count? uint32 | +-- count? uint32
+-- recurrence-description? string +-- recurrence-description? string
+-- frequency? identityref +-- frequency? identityref
+-- interval? uint32 +-- interval? uint32
~~~~ ~~~~
{: #rec-utc-grp-tree title="'recurrence-utc' Grouping Tree Structure"} {: #rec-utc-grp-tree title="'recurrence-utc' Grouping Tree Structure"}
The "start-time-utc" indicates the start time in UTC format. The "start-time-utc" parameter indicates the start time in UTC format.
The "duration" parameter specifies, in units of seconds, the time period of The "duration" parameter specifies, in units of seconds, the time period of
the first occurrence. Unless specified otherwise (e.g., through additional the first occurrence. Unless specified otherwise (e.g., through additional
augmented parameters), the "duration" also applies to subsequent recurrence augmented parameters), the "duration" also applies to subsequent recurrence
instances. When unspecified, each occurrence is considered as instances. When unspecified, each occurrence is considered as
immediate completion (e.g., execute an immediate command that is considered immediate completion (e.g., execute an immediate command that is considered
to complete quickly) or hard to compute an exact duration (e.g., run a data to complete quickly) or hard to compute an exact duration (e.g., run a data
analysis script whose execution time may depend on the data volume and analysis script whose execution time may depend on the data volume and
computation resource availability). The behavior to follow when a task takes computation resource availability). The behavior to follow when a task takes
more time than specified by the "duration" is out of scope. Such considerations more time than specified by the "duration" is out of scope. Such considerations
belong to task management, not schedule management. belong to task management, not schedule management.
Note that the "interval" and "duration" cover two distinct properties of a schedul e event. Note that the "interval" and "duration" cover two distinct properties of a schedul e event.
The interval specifies when a schedule will occur, combined with the frequency parame ter; while the duration indicates how long The interval specifies when a schedule will occur, combined with the frequency parame ter, while the duration indicates how long
an occurrence will last. This document allows the interval between occurrences to be shorter than the duration of each occurrence (e.g., a recurring event is scheduled to start every day for a duration of 2 days). an occurrence will last. This document allows the interval between occurrences to be shorter than the duration of each occurrence (e.g., a recurring event is scheduled to start every day for a duration of 2 days).
The repetition can be scoped by a specified end time or by a count of occurrences, The repetition can be scoped by a specified end time or by a count of occurrences,
indicated by the "recurrence-end" choice. The "count" value MUST be greater than 1, the "start-time-utc" value always counts indicated by the "recurrence-end" choice. The "count" value MUST be greater than 1, and the "start-time-utc" value always counts
as the first occurrence. as the first occurrence.
The "recurrence-utc" grouping is designed to be reused in scheduling contexts The "recurrence-utc" grouping is designed to be reused in scheduling contexts
where machine readability is more desirable. where machine readability is more desirable.
### The "recurrence-with-time-zone" Grouping {#sec-rec-tz} ### The "recurrence-with-time-zone" Grouping {#sec-rec-tz}
The "recurrence-with-time-zone" grouping ({{rec-tz-grp-tree}}) uses the The "recurrence-with-time-zone" grouping ({{rec-tz-grp-tree}}) uses the
"recurrence-basic" grouping ({{sec-rec}}) and specifies a simple recurrence rule w ith a time zone. "recurrence-basic" grouping ({{sec-rec}}) and specifies a simple recurrence rule w ith a time zone.
~~~~ ~~~~ yangtree
grouping recurrence-with-time-zone: grouping recurrence-with-time-zone:
+-- recurrence-first +-- recurrence-first
| +-- start-time? yang:date-and-time | +-- start-time? yang:date-and-time
| +-- duration? duration | +-- duration? duration
+-- time-zone-identifier? sys:timezone-name +-- time-zone-identifier? sys:timezone-name
+-- (recurrence-end)? +-- (recurrence-end)?
| +--:(until) | +--:(until)
| | +-- until? yang:date-and-time | | +-- until? yang:date-and-time
| +--:(count) | +--:(count)
| +-- count? uint32 | +-- count? uint32
skipping to change at line 371 skipping to change at line 478
The "recurrence-first" container includes "start-time" and "duration" parameters The "recurrence-first" container includes "start-time" and "duration" parameters
to specify the start time and period of the first occurrence. Unless specified oth erwise (e.g., through additional to specify the start time and period of the first occurrence. Unless specified oth erwise (e.g., through additional
augmented parameters), the "duration" also applies to subsequent recurrence instan ces. When unspecified, each occurrence is considered as augmented parameters), the "duration" also applies to subsequent recurrence instan ces. When unspecified, each occurrence is considered as
immediate completion (e.g., execute an immediate command that is considered immediate completion (e.g., execute an immediate command that is considered
to complete quickly) or hard to compute an exact duration (e.g., run a data to complete quickly) or hard to compute an exact duration (e.g., run a data
analysis script whose execution time may depend on the data volume and analysis script whose execution time may depend on the data volume and
computation resource availability). computation resource availability).
The grouping also includes a The grouping also includes a
"time-zone-identifier" parameter which MUST be specified if either the "start-time " or "until" "time-zone-identifier" parameter, which MUST be specified if either the "start-tim e" or "until"
value is reported in local time format. It MUST NOT be applied to date and time value is reported in local time format. It MUST NOT be applied to date and time
values which are specified in the format of UTC or time zone offset to UTC. values that are specified in the format of UTC or time zone offset to UTC.
The repetition can be scoped by a specified end time or by a count of occurrences, The repetition can be scoped by a specified end time or by a count of occurrences,
indicated by the "recurrence-end" choice. The "count" value MUST be greater than 1, the "start-time" value always counts indicated by the "recurrence-end" choice. The "count" value MUST be greater than 1, and the "start-time" value always counts
as the first occurrence. as the first occurrence.
The considerations discussed in {{sec-rec-utc}} for "interval" and "duration" are a lso applicable to "recurrence-with-time-zone". The considerations discussed in {{sec-rec-utc}} for "interval" and "duration" are a lso applicable to "recurrence-with-time-zone".
Unlike the definition of "recurrence-utc" grouping ({{sec-rec-utc}}), Unlike the definition of the "recurrence-utc" grouping ({{sec-rec-utc}}),
"recurrence-with-time-zone" is intended to promote human readability over "recurrence-with-time-zone" is intended to promote human readability over
machine readability. machine readability.
### The "recurrence-utc-with-periods" Grouping {#sec-rec-utc-dt} ### The "recurrence-utc-with-periods" Grouping {#sec-rec-utc-dt}
The "recurrence-utc-with-periods" grouping ({{rec-utc-dt-grp-tree}}) uses The "recurrence-utc-with-periods" grouping ({{rec-utc-dt-grp-tree}}) uses
the "recurrence-utc" grouping ({{sec-rec-utc}}) and adds a "period-timeticks" the "recurrence-utc" grouping ({{sec-rec-utc}}) and adds a "period-timeticks"
list to define an aggregate set of repeating occurrences. list to define an aggregate set of repeating occurrences.
~~~~ ~~~~ yangtree
grouping recurrence-utc-with-periods: grouping recurrence-utc-with-periods:
+-- recurrence-first +-- recurrence-first
| +-- start-time-utc? yang:date-and-time | +-- start-time-utc? yang:date-and-time
| +-- duration? uint32 | +-- duration? uint32
+-- (recurrence-end)? +-- (recurrence-end)?
| +--:(until) | +--:(until)
| | +-- utc-until? yang:date-and-time | | +-- utc-until? yang:date-and-time
| +--:(count) | +--:(count)
| +-- count? uint32 | +-- count? uint32
+-- recurrence-description? string +-- recurrence-description? string
+-- frequency? identityref +-- frequency? identityref
+-- interval? uint32 +-- interval? uint32
+-- period-timeticks* [period-start] +-- period-timeticks* [period-start]
+-- period-start yang:timeticks +-- period-start yang:timeticks
+-- period-end? yang:timeticks +-- period-end? yang:timeticks
~~~~ ~~~~
{: #rec-utc-dt-grp-tree title="'recurrence-utc-with-periods' Grouping Tree Structure" } {: #rec-utc-dt-grp-tree title="'recurrence-utc-with-periods' Grouping Tree Structure" }
<!--[rfced] For conciseness, may we shorten "the value indicated by the value
of the..." in the sentence below as follows?
Original:
The value of the "period-start" instance MUST
NOT exceed the value indicated by the value of "frequency" instance...
Perhaps:
The value of the "period-start" instance MUST
NOT exceed the value of the "frequency" instance...
-->
The recurrence instances are specified by the union of occurrences defined The recurrence instances are specified by the union of occurrences defined
by both the recurrence rule and "period-timeticks" list. This list uses by both the recurrence rule and "period-timeticks" list. This list uses the
"yang:timeticks" type defined in {{!RFC6991}}. Duplicate instances "yang:timeticks" type defined in {{!RFC6991}}. Duplicate instances
are ignored. The value of the "period-start" instance MUST NOT exceed the are ignored. The value of the "period-start" instance MUST NOT exceed the
value indicated by the value of "frequency" instance, i.e., the timeticks value indicated by the value of the "frequency" instance, i.e., the "timeticks"
value must not exceed 100 in a secondly recurrence rule, and it must not value must not exceed 100 in a secondly recurrence rule, and it must not
exceed 6000 in a minutely recurrence rule, and so on. exceed 6000 in a minutely recurrence rule, and so on.
### The "recurrence-time-zone-with-periods" Grouping {#sec-rec-tz-dt} ### The "recurrence-time-zone-with-periods" Grouping {#sec-rec-tz-dt}
The "recurrence-time-zone-with-periods" grouping ({{rec-tz-dt-grp-tree}}) uses The "recurrence-time-zone-with-periods" grouping ({{rec-tz-dt-grp-tree}}) uses
the "recurrence-with-time-zone" grouping ({{sec-rec-tz}}) and the "recurrence-with-time-zone" grouping ({{sec-rec-tz}}) and
adds a "period" list to define an aggregate set of repeating occurrences. adds a "period" list to define an aggregate set of repeating occurrences.
~~~~ ~~~~ yangtree
grouping recurrence-time-zone-with-periods: grouping recurrence-time-zone-with-periods:
+-- recurrence-first +-- recurrence-first
| +-- start-time? yang:date-and-time | +-- start-time? yang:date-and-time
| +-- duration? duration | +-- duration? duration
+-- time-zone-identifier? sys:timezone-name +-- time-zone-identifier? sys:timezone-name
+-- (recurrence-end)? +-- (recurrence-end)?
| +--:(until) | +--:(until)
| | +-- until? yang:date-and-time | | +-- until? yang:date-and-time
| +--:(count) | +--:(count)
| +-- count? uint32 | +-- count? uint32
skipping to change at line 459 skipping to change at line 578
The recurrence instances are specified by the union of occurrences defined The recurrence instances are specified by the union of occurrences defined
by both the recurrence rule and "period" list. Duplicate instances by both the recurrence rule and "period" list. Duplicate instances
are ignored. are ignored.
### The "icalendar-recurrence" Grouping {#sec-ical-rec} ### The "icalendar-recurrence" Grouping {#sec-ical-rec}
The "icalendar-recurrence" grouping ({{ical-grp-tree}}) uses the The "icalendar-recurrence" grouping ({{ical-grp-tree}}) uses the
"recurrence-time-zone-with-periods" grouping ({{sec-rec-tz-dt}}) and defines "recurrence-time-zone-with-periods" grouping ({{sec-rec-tz-dt}}) and defines
more data nodes to enrich the definition of recurrence. The structure of the more data nodes to enrich the definition of recurrence. The structure of the
"icalendar-recurrence" grouping refers to the definition of recurrence "icalendar-recurrence" grouping refers to the definition of the recurrence
component defined in {{Sections 3.3.10 and 3.8.5 of !RFC5545}}. component defined in {{Sections 3.3.10 and 3.8.5 of !RFC5545}}.
~~~~ ~~~~ yangtree
grouping icalendar-recurrence: grouping icalendar-recurrence:
+-- recurrence-first +-- recurrence-first
| +-- start-time? yang:date-and-time | +-- start-time? yang:date-and-time
| +-- duration? duration | +-- duration? duration
+-- time-zone-identifier? sys:timezone-name +-- time-zone-identifier? sys:timezone-name
+-- (recurrence-end)? +-- (recurrence-end)?
| +--:(until) | +--:(until)
| | +-- until? yang:date-and-time | | +-- until? yang:date-and-time
| +--:(count) | +--:(count)
| +-- count? uint32 | +-- count? uint32
skipping to change at line 501 skipping to change at line 620
+-- bymonthday* int32 +-- bymonthday* int32
+-- byyearday* int32 +-- byyearday* int32
+-- byyearweek* int32 +-- byyearweek* int32
+-- byyearmonth* uint32 +-- byyearmonth* uint32
+-- bysetpos* int32 +-- bysetpos* int32
+-- workweek-start? schedule:weekday +-- workweek-start? schedule:weekday
+-- exception-dates* yang:date-and-time +-- exception-dates* yang:date-and-time
~~~~ ~~~~
{: #ical-grp-tree title="'icalendar-recurrence' Grouping Tree Structure"} {: #ical-grp-tree title="'icalendar-recurrence' Grouping Tree Structure"}
An array of the "bysecond" (or "byminute", "byhour") specifies a list of An array of the "bysecond" (or "byminute" or "byhour") specifies a list of
seconds within a minute (or minutes within an hour, hours of the day). For seconds within a minute (or minutes within an hour or hours of the day). For
example, within a "minutely" recurrence rule, the values of "byminute" node example, within a "minutely" recurrence rule, the values of "byminute" node
"10" and "20" means the occurrences are generated at the 10th and 20th minute "10" and "20" mean the occurrences are generated at the 10th and 20th minute
within an hour, reducing the number of recurrence instances from all minutes. within an hour, reducing the number of recurrence instances from all minutes.
The parameter "byday" specifies a list of days of the week, with an optional The parameter "byday" specifies a list of days of the week, with an optional
direction which indicates the nth occurrence of a specific day within direction that indicates the nth occurrence of a specific day within
the "monthly" or "yearly" frequency instance. Valid values of "direction" are 1 to the "monthly" or "yearly" frequency instance. Valid values of "direction" are 1 to
5 or -5 to -1 within a "monthly" recurrence rule; and 1 to 53 or -53 to -1 within a 5 or -5 to -1 within a "monthly" recurrence rule and 1 to 53 or -53 to -1 within a "
"yearly" recurrence rule. For example, within a "monthly" rule, yearly" recurrence rule. For example, within a "monthly" rule,
the "weekday" with a value of "monday" and the "direction" with a value of "-1" the "weekday" with a value of "monday" and the "direction" with a value of "-1"
represents the last Monday of the month. represents the last Monday of the month.
An array of the "bymonthday" (or byyearday", "byyearweek", or "byyearmonth") speci fies a list of An array of the "bymonthday" (or byyearday", "byyearweek", or "byyearmonth") speci fies a list of
days of the month (or days of the year, weeks of the year, or months of the year). days of the month (or days of the year, weeks of the year, or months of the year).
For example, within a "yearly" recurrence rule, the values of "byyearmonth" For example, within a "yearly" recurrence rule, the values of "byyearmonth"
instance "1" and "2" means the occurrences are generated in January and February, instances "1" and "2" mean the occurrences are generated in January and February,
increasing the "yearly" recurrence from every year to every January and February increasing the "yearly" recurrence from every year to every January and February
of the year. of the year.
The "bysetpos" conveys a list of values that corresponds to the nth occurrence The "bysetpos" conveys a list of values that corresponds to the nth occurrence
within the set of recurrence instances to be specified. For example, in a "monthly " within the set of recurrence instances to be specified. For example, in a "monthly "
recurrence rule, the "byday" data node specifies every Monday of the week, the recurrence rule, the "byday" data node specifies every Monday of the week, and the
"bysetpos" with value of "-1" represents the last Monday of the month. "bysetpos" with a value of "-1" represents the last Monday of the month.
Not setting the "bysetpos" data node represents every Monday of the month. Not setting the "bysetpos" data node represents every Monday of the month.
The "workweek-start" data node specifies the day on which the week starts. This is The "workweek-start" data node specifies the day on which the week starts. This is
significant when a "weekly" recurrence rule has an interval greater than 1, and significant when a "weekly" recurrence rule has an interval greater than 1, and
a "byday" data node is specified. This is also significant when in a "yearly" rule a "byday" data node is specified. This is also significant when in a "yearly" rule
and a "byyearweek" is specified. Note that per {{Section 4.13 of ?I-D.ietf-netmod- rfc8407bis}}, neither a "default" and a "byyearweek" is specified. Note that, per {{Section 4.13 of ?I-D.ietf-netmod -rfc8407bis}}, neither a "default"
nor a "mandatory" substatement is defined here because there are cases (e.g., prof iling) nor a "mandatory" substatement is defined here because there are cases (e.g., prof iling)
where using these statements is problematic. where using these statements is problematic.
YANG modules using this grouping SHOULD refine the "workweek-start" node with eith er a YANG modules using this grouping SHOULD refine the "workweek-start" node with eith er a
"mandatory" or a "default" statement, if it always needs to be configured or has a default value. "mandatory" or a "default" statement if it always needs to be configured or has a default value.
This MAY be ignored in cases such as when this grouping is used by another groupin g. This MAY be ignored in cases such as when this grouping is used by another groupin g.
The "exception-dates" data node specifies a list of exceptions for recurrence. The The "exception-dates" data node specifies a list of exceptions for recurrence. The
final recurrence set is generated by gathering all of the date and time values final recurrence set is generated by gathering all of the date and time values
created by any of the specified recurrence rule and date-times, and then created by any of the specified recurrence rules and date-times and then
excluding any start date and time values specified by "exception-dates" parameter. excluding any start date and time values specified by "exception-dates" parameter.
### The "schedule-status", "schedule-status-with-time-zone", and "schedule-status-wit h-name" Groupings {#sec-schedule-status} ### The "schedule-status", "schedule-status-with-time-zone", and "schedule-status-wit h-name" Groupings {#sec-schedule-status}
The "schedule-status", "schedule-status-with-time-zone", and "schedule-status-with -name" groupings ({{sche-status-tree}}) define common parameters The "schedule-status", "schedule-status-with-time-zone", and "schedule-status-with -name" groupings ({{sche-status-tree}}) define common parameters
for scheduling management/status exposure. The "schedule-status-with-time-zone" gr ouping has the same for scheduling management/status exposure. The "schedule-status-with-time-zone" gr ouping has the same
structure as "schedule-status" but with an additional parameter to identify a time zone. Similarly, the "schedule-status-with-name" grouping has the same structure as "schedule-status" but with an additional parameter to identify a schedule "schedule-n ame". These structure as "schedule-status" but with an additional parameter to identify a time zone. Similarly, the "schedule-status-with-name" grouping has the same structure as "schedule-status" but with an additional parameter to identify a schedule "schedule-n ame". These
structures are defined in the module to allow for better modularity and flexibilit y. structures are defined in the module to allow for better modularity and flexibilit y.
~~~~ <!--[rfced] In the title of Figure 9, is the asterisk (*) in
"schedule-status-*" correct? We ask as we do not see this elsewhere in
the document.
Current:
Figure 9: 'schedule-status-*' Groupings Tree Structure
Perhaps:
Figure 9: 'schedule-status' Groupings Tree Structure
-->
~~~~ yangtree
grouping schedule-status: grouping schedule-status:
+-- state? identityref +-- state? identityref
+-- version? uint16 +-- version? uint16
+-- schedule-type? identityref +-- schedule-type? identityref
+--ro local-time? yang:date-and-time +--ro local-time? yang:date-and-time
+--ro last-update? yang:date-and-time +--ro last-update? yang:date-and-time
+--ro counter? yang:counter32 +--ro counter? yang:counter32
+--ro last-occurrence? yang:date-and-time +--ro last-occurrence? yang:date-and-time
+--ro upcoming-occurrence? yang:date-and-time +--ro upcoming-occurrence? yang:date-and-time
+--ro last-failed-occurrence? yang:date-and-time +--ro last-failed-occurrence? yang:date-and-time
skipping to change at line 623 skipping to change at line 753
The current groupings capture common parameters that are applicable The current groupings capture common parameters that are applicable
to typical scheduling contexts known so far. Future modules can define other to typical scheduling contexts known so far. Future modules can define other
useful parameters as needed. For example, in a scheduling context with multiple useful parameters as needed. For example, in a scheduling context with multiple
system sources to feed the schedules, the "source" and "precedence" parameters system sources to feed the schedules, the "source" and "precedence" parameters
may be needed to reflect how schedules from different sources should be prioritize d. may be needed to reflect how schedules from different sources should be prioritize d.
## Features Use and Augmentations {#sec-aug} ## Features Use and Augmentations {#sec-aug}
{{features}} provides an example about how the features defined in {{sec-features} } can be used. Implementations {{features}} provides an example about how the features defined in {{sec-features} } can be used. Implementations
may support a basic recurrence rule or an advanced one as needed, by declaring may support a basic recurrence rule or an advanced one, as needed, by declaring
different features. Whether only one or both features are supported is implementat ion different features. Whether only one or both features are supported is implementat ion
specific and depends on the specific scheduling context. specific and depends on the specific scheduling context.
The common schedule groupings ({{sec-grp}}) can also be augmented to support speci fic needs. As an example, The common schedule groupings ({{sec-grp}}) can also be augmented to support speci fic needs. As an example,
{{augments}} demonstrates how additional parameters can be added to comply with sp ecific schedule needs. {{augments}} demonstrates how additional parameters can be added to comply with sp ecific schedule needs.
# Some Usage Restrictions # Some Usage Restrictions
There are some restrictions that need to be followed when using groupings defined There are some restrictions that need to be followed when using groupings defined
in the "ietf-schedule" YANG module ({{sec-grp}}): in the "ietf-schedule" YANG module ({{sec-grp}}):
* The instant in time represented by "period-start" MUST be before the * The instant in time represented by "period-start" MUST be before the
"period-end" for "period-of-time" grouping ({{sec-period}}). "period-end" for the "period-of-time" grouping ({{sec-period}}).
* The combination of the day, month, and year represented for date and time * The combination of the day, month, and year represented for date and time
values MUST be valid. See {{Section 5.7 of ?RFC3339}} for the maximum day values MUST be valid. See {{Section 5.7 of ?RFC3339}} for the maximum day
number based on the month and year. number based on the month and year.
* Unless deployed in contexts where time synchronization is not subject to leap s econd adjustments (e.g., {{Section 4.3 of ?I-D.ietf-ntp-ntpv5}}), the second for date and time values SHOULD have the value "60" at the end of months in which a leap * Unless deployed in contexts where time synchronization is not subject to leap s econd adjustments (e.g., {{Section 4.3 of ?I-D.ietf-ntp-ntpv5}}), the second for date and time values SHOULD have the value "60" at the end of months in which a leap
second occurs. second occurs.
* Schedules received with a starting time in the past with respect to * Schedules received with a starting time in the past with respect to
current time SHOULD be ignored. When a local policy is provided, an implementat ion MAY omit the past occurrences and current time SHOULD be ignored. When a local policy is provided, an implementat ion MAY omit the past occurrences and
start immediately (e.g., for a period-based schedule) or starts from the start immediately (e.g., for a period-based schedule) or start from the
date and time when the recurrence pattern is first satisfied from the current t ime (e.g., for a recurrence-based schedule). date and time when the recurrence pattern is first satisfied from the current t ime (e.g., for a recurrence-based schedule).
# Relationship to the DISMAN-SCHEDULE-MIB {#sec-mib} # Relationship to the DISMAN-SCHEDULE-MIB {#sec-mib}
{{!RFC3231}} specifies a Management Information Base (MIB) used to {{!RFC3231}} specifies a Management Information Base (MIB) used to
schedule management operations periodically or at specified dates and times. schedule management operations periodically or at specified dates and times.
Although no data nodes are defined in this document, {{mapping}} lists Although no data nodes are defined in this document, {{mapping}} lists
how the main objects in the DISMAN-SCHEDULE-MIB can be mapped to YANG how the main objects in the DISMAN-SCHEDULE-MIB can be mapped to YANG
parameters. parameters.
|MIB Object| YANG| |MIB Object|YANG|
|----------|---| |----------|---|
|schedLocalTime| local-time | |schedLocalTime| local-time |
|schedType | schedule-type| |schedType | schedule-type|
|schedName| schedule-name | |schedName| schedule-name |
|schedOwner| Not Supported | |schedOwner| Not Supported |
|schedDescr| description | |schedDescr| description |
|schedInterval|interval | |schedInterval|interval |
|schedWeekDay| weekday | |schedWeekDay| weekday |
|schedMonth| byyearmonth | |schedMonth| byyearmonth |
|schedDay| bymonthday | |schedDay| bymonthday |
skipping to change at line 683 skipping to change at line 813
|schedLastFailure| Not Supported | |schedLastFailure| Not Supported |
|schedLastFailed| last-failed-occurrence| |schedLastFailed| last-failed-occurrence|
|schedStorageType| Not Supported | |schedStorageType| Not Supported |
|schedVariable| Not applicable | |schedVariable| Not applicable |
|schedValue| Not applicable | |schedValue| Not applicable |
|schedTriggers| counter/failure-counter | |schedTriggers| counter/failure-counter |
{: #mapping title="YANG/MIB Mapping"} {: #mapping title="YANG/MIB Mapping"}
# The "ietf-schedule" YANG Module {#sec-schedule} # The "ietf-schedule" YANG Module {#sec-schedule}
This module imports types defined in {{!RFC6991}} and {{!RFC7317}}. <!--[rfced] FYI - As RFC 5545 is also cited within the "ietf-schedule"
module, we've added it to the list of RFCs preceding the module.
~~~~ Original:
<CODE BEGINS> file ietf-schedule@2025-05-30.yang This module imports types defined in [RFC6991] and [RFC7317].
Current:
This module imports types defined in [RFC5545], [RFC6991], and [RFC7317].
-->
<!--[rfced] FYI - We made the following update to the format in the
"ietf-schedule" YANG module using the formatting option of pyang.
Original:
error-message
"Frequency must be provided.";
Current:
error-message "Frequency must be provided.";
-->
This module imports types defined in {{!RFC5545}}, {{!RFC6991}}, and {{!RFC7317}}.
~~~~ yang
file "ietf-schedule@2026-02-18.yang"
module ietf-schedule { module ietf-schedule {
yang-version 1.1; yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-schedule"; namespace "urn:ietf:params:xml:ns:yang:ietf-schedule";
prefix schedule; prefix schedule;
import ietf-yang-types { import ietf-yang-types {
prefix yang; prefix yang;
reference reference
"RFC 6991: Common YANG Data Types"; "RFC 6991: Common YANG Data Types";
} }
import ietf-system { import ietf-system {
prefix sys; prefix sys;
reference reference
"RFC 7317: A YANG Data Model for System Management"; "RFC 7317: A YANG Data Model for System Management";
} }
organization organization
"IETF NETMOD Working Group"; "IETF NETMOD Working Group";
contact contact
"WG Web: <https://datatracker.ietf.org/wg/netmod/> "WG Web: <https://datatracker.ietf.org/wg/netmod/>
WG List: <mailto:netmod@ietf.org> WG List: <mailto:netmod@ietf.org>
Editor: Qiufang Ma Editor: Qiufang Ma
<mailto:maqiufang1@huawei.com <mailto:maqiufang1@huawei.com>
Author: Qin Wu Author: Qin Wu
<mailto:bill.wu@huawei.com> <mailto:bill.wu@huawei.com>
Editor: Mohamed Boucadair Editor: Mohamed Boucadair
<mailto:mohamed.boucadair@orange.com> <mailto:mohamed.boucadair@orange.com>
Author: Daniel King Author: Daniel King
<mailto:d.king@lancaster.ac.uk>"; <mailto:d.king@lancaster.ac.uk>";
description description
"This YANG module defines a set of common types and groupings "This YANG module defines a set of common types and groupings
which are applicable for scheduling purposes such as events, that are applicable for scheduling purposes, such as events,
policy, services, or resources based on date and time. policies, services, or resources based on date and time.
Copyright (c) 2025 IETF Trust and the persons identified The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL
as authors of the code. All rights reserved. NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED',
'MAY', and 'OPTIONAL' in this document are to be interpreted as
described in BCP 14 (RFC 2119) (RFC 8174) when, and only when,
they appear in all capitals, as shown here.
Copyright (c) 2026 IETF Trust and the persons identified
as authors of the code. All rights reserved.
Redistribution and use in source and binary forms, with Redistribution and use in source and binary forms, with
or without modification, is permitted pursuant to, and or without modification, is permitted pursuant to, and
subject to the license terms contained in, the Revised subject to the license terms contained in, the Revised
BSD License set forth in Section 4.c of the IETF Trust's BSD License set forth in Section 4.c of the IETF Trust's
Legal Provisions Relating to IETF Documents Legal Provisions Relating to IETF Documents
(https://trustee.ietf.org/license-info). (https://trustee.ietf.org/license-info).
All revisions of IETF and IANA published modules can be found This version of this YANG module is part of RFC 9922; see
at the YANG Parameters registry group
(https://www.iana.org/assignments/yang-parameters).
This version of this YANG module is part of RFC XXXX; see
the RFC itself for full legal notices. the RFC itself for full legal notices.
The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL All revisions of IETF and IANA-maintained modules can be found
NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', in the 'YANG Parameters' registry group
'MAY', and 'OPTIONAL' in this document are to be interpreted as (https://www.iana.org/assignments/yang-parameters).";
described in BCP 14 (RFC 2119) (RFC 8174) when, and only when,
they appear in all capitals, as shown here.";
revision 2025-05-30 { revision 2026-02-18 {
description description
"Initial revision."; "Initial revision.";
reference reference
"RFC XXXX: A Common YANG Data Model for Scheduling"; "RFC 9922: A Common YANG Data Model for Scheduling";
} }
feature basic-recurrence { feature basic-recurrence {
description description
"Indicates that the server supports configuring a basic "Indicates that the server supports configuring a basic
scheduled recurrence."; scheduled recurrence.";
} }
feature icalendar-recurrence { feature icalendar-recurrence {
description description
"Indicates that the server supports configuring a comprehensive "Indicates that the server supports configuring a comprehensive
scheduled iCalendar recurrence"; scheduled iCalendar recurrence.";
reference reference
"RFC 5545: Internet Calendaring and Scheduling Core Object "RFC 5545: Internet Calendaring and Scheduling Core Object
Specification (iCalendar), Specification (iCalendar),
Sections 3.3.10 and 3.8.5"; Sections 3.3.10 and 3.8.5";
} }
typedef weekday { typedef weekday {
type enumeration { type enumeration {
enum sunday { enum sunday {
value 0; value 0;
skipping to change at line 817 skipping to change at line 968
description description
"Seven days of the week."; "Seven days of the week.";
} }
typedef duration { typedef duration {
type string { type string {
pattern '((\+)?|\-)P((([0-9]+)D)?(T(0[0-9]|1[0-9]|2[0-3])' pattern '((\+)?|\-)P((([0-9]+)D)?(T(0[0-9]|1[0-9]|2[0-3])'
+ ':[0-5][0-9]:[0-5][0-9]))|P([0-9]+)W'; + ':[0-5][0-9]:[0-5][0-9]))|P([0-9]+)W';
} }
description description
"Duration of the time. The format can represent nominal "Duration of the time. The format can represent nominal
durations (weeks designated by 'W' and days designated by 'D') durations (weeks designated by 'W' and days designated by 'D')
and accurate durations (hours:minutes:seconds follows the and accurate durations (hours:minutes:seconds follows the
designator 'T'). designator 'T').
Note that this value type doesn't support the 'Y' and 'M' Note that this value type doesn't support the 'Y' and 'M'
designators to specify durations in terms of years and months. designators to specify durations in terms of years and months.
Negative durations are typically used to schedule an alarm to Negative durations are typically used to schedule an alarm to
trigger before an associated time."; trigger before an associated time.";
reference reference
skipping to change at line 841 skipping to change at line 992
} }
identity schedule-type { identity schedule-type {
description description
"Base identity for schedule type."; "Base identity for schedule type.";
} }
identity one-shot { identity one-shot {
base schedule-type; base schedule-type;
description description
"Indicates a one-shot schedule. That is a schedule that "Indicates a one-shot schedule. That is a schedule that
will trigger an action with the duration being specified as will trigger an action with the duration being specified as
0 or end time being specified the same as start time, 0 or end time being specified as the same as the start time,
and then the schedule will disable itself."; and then the schedule will disable itself.";
} }
identity period { identity period {
base schedule-type; base schedule-type;
description description
"Indicates a period-based schedule consisting of either a "Indicates a period-based schedule consisting of either a
start and end or a start and positive duration of time. If start and end or a start and positive duration of time. If
neither an end nor a duration is indicated, the period is neither an end nor a duration is indicated, the period is
considered to last forever."; considered to last forever.";
} }
identity recurrence { identity recurrence {
base schedule-type; base schedule-type;
description description
"Indicates a recurrence-based schedule."; "Indicates a recurrence-based schedule.";
} }
skipping to change at line 996 skipping to change at line 1147
Such parameters are used as guards to prevent, e.g., stale Such parameters are used as guards to prevent, e.g., stale
configuration."; configuration.";
leaf description { leaf description {
type string; type string;
description description
"Provides a description of the schedule."; "Provides a description of the schedule.";
} }
leaf time-zone-identifier { leaf time-zone-identifier {
type sys:timezone-name; type sys:timezone-name;
description description
"Indicates the identifier for the time zone. This parameter "Indicates the identifier for the time zone. This parameter
MUST be specified if any of the date and time values are MUST be specified if any of the date and time values are
in the format of local time. It MUST NOT be applied to in the format of local time. It MUST NOT be applied to
date and time values which are specified in the format of date and time values that are specified in the format of
UTC or time zone offset to UTC."; UTC or time zone offset to UTC.";
} }
leaf validity { leaf validity {
type yang:date-and-time; type yang:date-and-time;
description description
"Specifies the date and time after which a schedule will not "Specifies the date and time after which a schedule will not
be considered as valid. This parameter takes precedence be considered as valid. This parameter takes precedence
over similar attributes that are provided at the schedule over similar attributes that are provided at the schedule
instance itself."; instance itself.";
} }
leaf max-allowed-start { leaf max-allowed-start {
type yang:date-and-time; type yang:date-and-time;
description description
"Specifies the maximum scheduled start date and time. "Specifies the maximum scheduled start date and time.
A requested schedule whose first instance occurs after A requested schedule whose first instance occurs after
this value cannot be accepted by the entity. Specifically, this value cannot be accepted by the entity. Specifically,
a requested schedule will be rejected if the first a requested schedule will be rejected if the first
occurrence of that schedule exceeds 'max-allowed-start'."; occurrence of that schedule exceeds 'max-allowed-start'.";
} }
leaf min-allowed-start { leaf min-allowed-start {
type yang:date-and-time; type yang:date-and-time;
description description
"Specifies the minimum scheduled start date and time. "Specifies the minimum scheduled start date and time.
A requested schedule whose first instance occurs before A requested schedule whose first instance occurs before
this value cannot be accepted by the entity. Specifically, this value cannot be accepted by the entity. Specifically,
a requested schedule will be rejected if the first a requested schedule will be rejected if the first
occurrence of that schedule is scheduled before occurrence of that schedule is scheduled before
'min-allowed-start'."; 'min-allowed-start'.";
} }
leaf max-allowed-end { leaf max-allowed-end {
type yang:date-and-time; type yang:date-and-time;
description description
"A requested schedule will be rejected if the end time of "A requested schedule will be rejected if the end time of
the last occurrence exceeds 'max-allowed-end'."; the last occurrence exceeds 'max-allowed-end'.";
} }
leaf discard-action { leaf discard-action {
type identityref { type identityref {
base discard-action-type; base discard-action-type;
} }
description description
"Specifies the behavior when a schedule is discarded for "Specifies the behavior when a schedule is discarded for
any reason, e.g., failing to satisfy the guards in this any reason, e.g., failing to satisfy the guards in this
grouping or it is received out-of-date."; grouping or being received out-of-date.";
} }
} }
grouping period-of-time { grouping period-of-time {
description description
"This grouping is defined for period of time property."; "This grouping is defined for the period of time property.";
reference reference
"RFC 5545: Internet Calendaring and Scheduling Core Object "RFC 5545: Internet Calendaring and Scheduling Core Object
Specification (iCalendar), Section 3.3.9"; Specification (iCalendar), Section 3.3.9";
leaf period-description { leaf period-description {
type string; type string;
description description
"Provides a description of the period."; "Provides a description of the period.";
} }
leaf period-start { leaf period-start {
type yang:date-and-time; type yang:date-and-time;
description description
"Period start time."; "Period start time.";
} }
leaf time-zone-identifier { leaf time-zone-identifier {
type sys:timezone-name; type sys:timezone-name;
description description
"Indicates the identifier for the time zone. This parameter "Indicates the identifier for the time zone. This parameter
MUST be specified if either the 'period-start' or MUST be specified if either the 'period-start' or
'period-end' value is reported in local time format. 'period-end' value is reported in local time format.
It MUST NOT be applied to date and time values which are It MUST NOT be applied to date and time values that are
specified in the format of UTC or time zone offset specified in the format of UTC or time zone offset
to UTC."; to UTC.";
} }
choice period-type { choice period-type {
description description
"Indicates the type of the time period. Two types are "Indicates the type of the time period. Two types are
supported. If no choice is indicated, the period is supported. If no choice is indicated, the period is
considered to last forever."; considered to last forever.";
case explicit { case explicit {
description description
"A period of time is identified by its start and its end. "A period of time is identified by its start and its end.
'period-start' indicates the period start."; 'period-start' indicates the period start.";
leaf period-end { leaf period-end {
type yang:date-and-time; type yang:date-and-time;
description description
"A period of time is defined by a start and end time. "A period of time is defined by a start and end time.
The start MUST be no later than the end. The period The start MUST be no later than the end. The period
is considered as a one-shot schedule if the end time is considered as a one-shot schedule if the end time
is the same as the start time."; is the same as the start time.";
} }
} }
case duration { case duration {
description description
"A period of time is defined by a start and a non-negative "A period of time is defined by a start and a non-negative
duration of time."; duration of time.";
leaf duration { leaf duration {
type duration { type duration {
pattern 'P((([0-9]+)D)?(T(0[0-9]|1[0-9]|2[0-3])' pattern 'P((([0-9]+)D)?(T(0[0-9]|1[0-9]|2[0-3])'
+ ':[0-5][0-9]:[0-5][0-9]))|P([0-9]+)W'; + ':[0-5][0-9]:[0-5][0-9]))|P([0-9]+)W';
} }
description description
"A non-negative duration of time. This value is "A non-negative duration of time. This value is
equivalent to the format of duration type except that equivalent to the format of 'duration' type except that
the value cannot be negative. The period is considered the value cannot be negative. The period is considered
to be a one-shot schedule if the value is 0."; to be a one-shot schedule if the value is 0.";
} }
} }
} }
} }
grouping recurrence-basic { grouping recurrence-basic {
description description
"A simple definition of recurrence."; "A simple definition of recurrence.";
leaf recurrence-description { leaf recurrence-description {
skipping to change at line 1129 skipping to change at line 1280
base frequency-type; base frequency-type;
} }
description description
"Specifies the frequency type of the recurrence rule."; "Specifies the frequency type of the recurrence rule.";
} }
leaf interval { leaf interval {
type uint32 { type uint32 {
range "1..max"; range "1..max";
} }
must '../frequency' { must '../frequency' {
error-message error-message "Frequency must be provided.";
"Frequency must be provided.";
} }
description description
"A positive integer representing interval at which the "A positive integer representing the interval at which the
recurrence rule repeats. For example, within a 'daily' recurrence rule repeats. For example, within a 'daily'
recurrence rule, a value of '8' means every eight days."; recurrence rule, a value of '8' means every eight days.";
} }
} }
grouping recurrence-utc { grouping recurrence-utc {
description description
"A simple definition of recurrence with time specified in "A simple definition of recurrence with time specified in
UTC format."; UTC format.";
container recurrence-first { container recurrence-first {
description description
"Specifies the first instance of the recurrence. If "Specifies the first instance of the recurrence. If
unspecified, the recurrence is considered to start from unspecified, the recurrence is considered to start from
the date and time when the recurrence pattern is first the date and time when the recurrence pattern is first
satisfied."; satisfied.";
leaf start-time-utc { leaf start-time-utc {
type yang:date-and-time; type yang:date-and-time;
description description
"Defines the date and time of the first instance "Defines the date and time of the first instance
in the recurrence set. A UTC format MUST be used."; in the recurrence set. A UTC format MUST be used.";
} }
leaf duration { leaf duration {
type uint32; type uint32;
units "seconds"; units "seconds";
description description
"When specified, it indicates how long the first occurrence "When specified, it indicates how long the first occurrence
lasts. Unless specified otherwise, it also applies to all lasts. Unless specified otherwise, it also applies to all
the other instances in the recurrence set."; the other instances in the recurrence set.";
} }
} }
choice recurrence-end { choice recurrence-end {
description description
"Modes to control the end of a recurrence rule. If no "Modes to control the end of a recurrence rule. If no
choice is indicated, the recurrence rule is considered choice is indicated, the recurrence rule is considered
to repeat forever."; to repeat forever.";
case until { case until {
description description
"This case defines a way that limits the end of "This case defines a way that limits the end of
a recurrence rule in an inclusive manner."; a recurrence rule in an inclusive manner.";
leaf utc-until { leaf utc-until {
type yang:date-and-time; type yang:date-and-time;
description description
"This parameter specifies a date and time value to "This parameter specifies a date and time value to
skipping to change at line 1206 skipping to change at line 1356
} }
uses recurrence-basic; uses recurrence-basic;
} }
grouping recurrence-with-time-zone { grouping recurrence-with-time-zone {
description description
"A simple definition of recurrence to specify a recurrence "A simple definition of recurrence to specify a recurrence
rule with a time zone."; rule with a time zone.";
container recurrence-first { container recurrence-first {
description description
"Specifies the first instance of the recurrence. If "Specifies the first instance of the recurrence. If
unspecified, the recurrence is considered to start from unspecified, the recurrence is considered to start from
the date and time when the recurrence pattern is first the date and time when the recurrence pattern is first
satisfied."; satisfied.";
leaf start-time { leaf start-time {
type yang:date-and-time; type yang:date-and-time;
description description
"Defines the date and time of the first instance "Defines the date and time of the first instance
in the recurrence set."; in the recurrence set.";
} }
leaf duration { leaf duration {
type duration; type duration;
description description
"When specified, it indicates how long the first "When specified, it indicates how long the first
occurrence last. Unless specified otherwise, it also occurrence lasts. Unless specified otherwise, it also
applies to all the other instances in the recurrence applies to all the other instances in the recurrence
set."; set.";
} }
} }
leaf time-zone-identifier { leaf time-zone-identifier {
type sys:timezone-name; type sys:timezone-name;
description description
"Indicates the identifier for the time zone in a time "Indicates the identifier for the time zone in a time
zone database. This parameter MUST be specified if either zone database. This parameter MUST be specified if either
the 'start-time' or 'until' value is reported in local the 'start-time' or 'until' value is reported in local
time format. It MUST NOT be applied to date and time time format. It MUST NOT be applied to date and time
values which are specified in the format of UTC or time values that are specified in the format of UTC or time
zone offset to UTC."; zone offset to UTC.";
} }
choice recurrence-end { choice recurrence-end {
description description
"Modes to terminate the recurrence rule. If no choice is "Modes to terminate the recurrence rule. If no choice is
indicated, the recurrence rule is considered to repeat indicated, the recurrence rule is considered to repeat
forever."; forever.";
case until { case until {
description description
"The end of the recurrence rule is indicated by a specific "The end of the recurrence rule is indicated by a specific
date-and-time value in an inclusive manner."; date-and-time value in an inclusive manner.";
leaf until { leaf until {
type yang:date-and-time; type yang:date-and-time;
description description
"Specifies a date and time value to inclusively terminate "Specifies a date and time value to inclusively terminate
the recurrence. Thats is, if the value specified by this the recurrence. That is, if the value specified by
parameter is synchronized with the specified recurrence, this parameter is synchronized with the specified
it becomes the last instance of the recurrence."; recurrence, it becomes the last instance of the
recurrence.";
} }
} }
case count { case count {
description description
"The end of the recurrence is indicated by the number "The end of the recurrence is indicated by the number
of occurrences."; of occurrences.";
leaf count { leaf count {
type uint32 { type uint32 {
range "1..max"; range "1..max";
} }
skipping to change at line 1273 skipping to change at line 1424
terminate the recurrence."; terminate the recurrence.";
} }
} }
} }
uses recurrence-basic; uses recurrence-basic;
} }
grouping recurrence-utc-with-periods { grouping recurrence-utc-with-periods {
description description
"This grouping defines an aggregate set of repeating "This grouping defines an aggregate set of repeating
occurrences with UTC time format. The recurrence instances occurrences with UTC time format. The recurrence instances
are specified by the occurrences defined by both the are specified by the occurrences defined by both the
recurrence rule and 'period-timeticks' list. Duplicate recurrence rule and 'period-timeticks' list. Duplicate
instances are ignored."; instances are ignored.";
uses recurrence-utc; uses recurrence-utc;
list period-timeticks { list period-timeticks {
key "period-start"; key "period-start";
description description
"A list of periods with timeticks formats."; "A list of periods with timeticks formats.";
leaf period-start { leaf period-start {
type yang:timeticks; type yang:timeticks;
must "(not(derived-from(../../frequency," must "(not(derived-from(../../frequency,"
+ "'schedule:secondly')) or (current() < 100)) and " + "'schedule:secondly')) or (current() < 100)) and "
skipping to change at line 1299 skipping to change at line 1450
+ " or (current() < 360000)) and " + " or (current() < 360000)) and "
+ "(not(derived-from(../../frequency,'schedule:daily'))" + "(not(derived-from(../../frequency,'schedule:daily'))"
+ " or (current() < 8640000)) and " + " or (current() < 8640000)) and "
+ "(not(derived-from(../../frequency,'schedule:weekly'))" + "(not(derived-from(../../frequency,'schedule:weekly'))"
+ " or (current() < 60480000)) and " + " or (current() < 60480000)) and "
+ "(not(derived-from(../../frequency," + "(not(derived-from(../../frequency,"
+ "'schedule:monthly')) or (current() < 267840000)) and " + "'schedule:monthly')) or (current() < 267840000)) and "
+ "(not(derived-from(../../frequency,'schedule:yearly'))" + "(not(derived-from(../../frequency,'schedule:yearly'))"
+ " or (current() < 3162240000))" { + " or (current() < 3162240000))" {
error-message error-message
"The period-start must not exceed the frequency "The 'period-start' must not exceed the frequency
interval."; interval.";
} }
description description
"Start time of the schedule within one recurrence. "Start time of the schedule within one recurrence.
Given that the value is in timeticks format Given that the value is in timeticks format
(i.e., 1/100 of a second), the values in the must (i.e., 1/100 of a second), the values in the must
statement translate to: 100 = 1s (secondly), statement translate to 100 = 1 s (secondly),
6000 = 60 s = 1 min (minutely), and so on for all 6000 = 60 s = 1 min (minutely), and so on for all
instances in the must statement invariant."; instances in the must statement invariant.";
} }
leaf period-end { leaf period-end {
type yang:timeticks; type yang:timeticks;
description description
"End time of the schedule within one recurrence. "End time of the schedule within one recurrence.
The period start MUST be no later than the period The period start MUST be no later than the period
end."; end.";
} }
skipping to change at line 1380 skipping to change at line 1531
when "derived-from(../../frequency, 'schedule:monthly') or " when "derived-from(../../frequency, 'schedule:monthly') or "
+ "(derived-from(../../frequency, 'schedule:yearly') " + "(derived-from(../../frequency, 'schedule:yearly') "
+ " and not(../../byyearweek))"; + " and not(../../byyearweek))";
type int32 { type int32 {
range "-53..-1|1..53"; range "-53..-1|1..53";
} }
description description
"When specified, it indicates the nth occurrence of a "When specified, it indicates the nth occurrence of a
specific day within the monthly or yearly recurrence specific day within the monthly or yearly recurrence
rule. For example, within a monthly rule, +1 monday rule. For example, within a monthly rule, +1 monday
represents the first monday within the month, whereas represents the first Monday within the month, whereas
-1 monday represents the last monday of the month."; -1 monday represents the last Monday of the month.";
} }
leaf weekday { leaf weekday {
type schedule:weekday; type schedule:weekday;
description description
"Corresponds to seven days of the week."; "Corresponds to seven days of the week.";
} }
} }
leaf-list bymonthday { leaf-list bymonthday {
type int32 { type int32 {
range "-31..-1|1..31"; range "-31..-1|1..31";
skipping to change at line 1426 skipping to change at line 1577
description description
"Specifies a list of months of the year."; "Specifies a list of months of the year.";
} }
leaf-list bysetpos { leaf-list bysetpos {
type int32 { type int32 {
range "-366..-1|1..366"; range "-366..-1|1..366";
} }
description description
"Specifies a list of values that corresponds to the nth "Specifies a list of values that corresponds to the nth
occurrence within the set of recurrence instances occurrence within the set of recurrence instances
specified by the rule. It must only be used in conjunction specified by the rule. It must only be used in conjunction
with another 'byxxx' (bysecond, byminute, etc.) rule with another 'byxxx' (bysecond, byminute, etc.) rule
part ."; part.";
} }
leaf workweek-start { leaf workweek-start {
type schedule:weekday; type schedule:weekday;
description description
"Specifies the day on which the workweek starts."; "Specifies the day on which the workweek starts.";
} }
leaf-list exception-dates { leaf-list exception-dates {
type yang:date-and-time; type yang:date-and-time;
description description
"Defines a list of exceptions for recurrence."; "Defines a list of exceptions for recurrence.";
skipping to change at line 1476 skipping to change at line 1627
type yang:date-and-time; type yang:date-and-time;
config false; config false;
description description
"Reports the local time as used by the entity that "Reports the local time as used by the entity that
hosts the schedule."; hosts the schedule.";
} }
leaf last-update { leaf last-update {
type yang:date-and-time; type yang:date-and-time;
config false; config false;
description description
"Reports the timestamp that the schedule is last updated."; "Reports the timestamp of when the schedule is last
updated.";
} }
leaf counter { leaf counter {
when "derived-from-or-self(../schedule-type, " when "derived-from-or-self(../schedule-type, "
+ "'schedule:recurrence')"; + "'schedule:recurrence')";
type yang:counter32; type yang:counter32;
config false; config false;
description description
"The number of occurrences while invoking the scheduled "The number of occurrences while invoking the scheduled
action successfully. The count wraps around when it reaches action successfully. The count wraps around when it reaches
the maximum value."; the maximum value.";
} }
leaf last-occurrence { leaf last-occurrence {
when "derived-from-or-self(../schedule-type, " when "derived-from-or-self(../schedule-type, "
+ "'schedule:recurrence')"; + "'schedule:recurrence')";
type yang:date-and-time; type yang:date-and-time;
config false; config false;
description description
"Indicates the timestamp of last occurrence."; "Indicates the timestamp of last occurrence.";
} }
skipping to change at line 1528 skipping to change at line 1680
config false; config false;
description description
"Counts the number of failures while invoking the scheduled "Counts the number of failures while invoking the scheduled
action."; action.";
} }
} }
grouping schedule-status-with-time-zone { grouping schedule-status-with-time-zone {
description description
"This grouping defines common properties of scheduling "This grouping defines common properties of scheduling
status, including timezone"; status, including timezone.";
leaf time-zone-identifier { leaf time-zone-identifier {
type sys:timezone-name; type sys:timezone-name;
config false; config false;
description description
"Indicates the identifier for the time zone in a time "Indicates the identifier for the time zone in a time
zone database."; zone database.";
} }
uses schedule-status; uses schedule-status;
} }
skipping to change at line 1553 skipping to change at line 1705
leaf schedule-name { leaf schedule-name {
type string; type string;
description description
"The schedule identifier that uniquely identifies a "The schedule identifier that uniquely identifies a
schedule within a device, controller, network, etc. schedule within a device, controller, network, etc.
The unicity scope depends on the implementation."; The unicity scope depends on the implementation.";
} }
uses schedule-status; uses schedule-status;
} }
} }
<CODE ENDS>
~~~~ ~~~~
{: sourcecode-markers="true"}
# Security Considerations # Security Considerations
This section uses the template described in {{Section 3.7 of ?I-D.ietf-netmod-rfc8407 bis}}. This section is modeled after the template described in {{Section 3.7 of ?I-D.ietf-ne tmod-rfc8407bis}}.
The "ietf-schedule" YANG module specified in this document defines schema for data <!--[rfced] *AD - Security Considerations Questions
a) FYI - We updated the Security Considerations section to
match the template at
<https://wiki.ietf.org/group/ops/yang-security-guidelines>.
Please review and let us know if any further updates are
needed.
b) As the Writable nodes, Readable nodes, and RFC/action operations
sections are not applicable to this document, do the following
sentences need to be added accordingly (per the template)?
- "There are no particularly sensitive writable data nodes."
- "There are no particularly sensitive readable data nodes."
- "There are no particularly sensitive RPC or action operations."
c) We note that in the paragraph that relates to the "No data nodes"
section, there is a sentence missing (i.e., from the template: "For
example, reusing some of these groupings will expose privacy-related
information (e.g., 'node-example')". Is that omission intentional or
should it be added for clarity?
From the template:
Modules that use the groupings that are defined in this document
should identify the corresponding security considerations. For
example, reusing some of these groupings will expose
privacy-related information (e.g., 'node-example').
Current text in the document:
Modules that use the groupings that are defined in this document
should identify the corresponding security considerations, for
example:
-->
The "ietf-schedule" YANG module defines a data model
that is designed to be accessed via YANG-based management protocols, such that is designed to be accessed via YANG-based management protocols, such
as NETCONF {{?RFC6241}} or RESTCONF {{?RFC8040}}. These YANG-based management pro tocols (1) have to use as NETCONF {{?RFC6241}} and RESTCONF {{?RFC8040}}. These YANG-based management pr otocols (1) have to use
a secure transport layer (e.g., SSH {{?RFC4252}}, TLS {{?RFC8446}}, and QUIC {{?RF C9000}}) a secure transport layer (e.g., SSH {{?RFC4252}}, TLS {{?RFC8446}}, and QUIC {{?RF C9000}})
and (2) have to use mutual authentication. and (2) have to use mutual authentication.
The Network Configuration Access Control Model (NACM) {{!RFC8341}} The Network Configuration Access Control Model (NACM) {{!RFC8341}}
provides the means to restrict access for particular NETCONF or provides the means to restrict access for particular NETCONF or
RESTCONF users to a preconfigured subset of all available NETCONF or RESTCONF users to a preconfigured subset of all available NETCONF or
RESTCONF protocol operations and content. RESTCONF protocol operations and content.
The "ietf-schedule" module defines a set of types and The "ietf-schedule" module defines a set of identities, types, and
groupings. These nodes are intended to be reused by other YANG groupings. These nodes are intended to be reused by other YANG
modules. The module by itself does not expose any data nodes that modules. The module by itself does not expose any data nodes that
are writable, data nodes that contain read-only state, or RPCs. As are writable, data nodes that contain read-only state, or RPCs. As
such, there are no additional security issues related to the "ietf-schedule" such, there are no additional security issues related to the "ietf-schedule"
module that need to be considered. module that need to be considered.
Modules that use the groupings that are defined in this document Modules that use the groupings that are defined in this document
should identify the corresponding security considerations, e.g.,: should identify the corresponding security considerations, for example:
* Scheduling depends on reliable and accurate time synchronization. Inaccurate dat e * Scheduling depends on reliable and accurate time synchronization. Inaccurate dat e
and time setting can lead to scheduling events being triggered at incorrect and time setting can lead to scheduling events being triggered at incorrect
intervals, potentially causing system failures or security vulnerabilities. intervals, potentially causing system failures or security vulnerabilities.
* Recurring events may conceal abnormal behavior or security threats, which * Recurring events may conceal abnormal behavior or security threats, which
may be drowned out by normal events, especially when they are triggered frequent ly. may be drowned out by normal events, especially when they are triggered frequent ly.
* The absence of detailed logs and audit records of each occurrence trigger time * The absence of detailed logs and audit records of each occurrence trigger time
and action results, and so on, may make security incidents difficult to trace. and action results and therefore may make security incidents difficult to trace.
* Care must be taken when defining recurrences occurring very often and * Care must be taken when defining recurrences occurring very often and
frequent that can be an additional source of attacks by keeping the system frequent that can be an additional source of attacks by keeping the system
permanently busy with the management of scheduling. permanently busy with the management of scheduling.
# IANA Considerations # IANA Considerations
## The "IETF XML" Registry ## The IETF XML Registry
This document registers the following URI in the "IETF XML Registry" {{!RFC3688}}. This document has registered the following URI in the "IETF XML Registry" {{!RFC36 88}}.
~~~~ URI:
URI: urn:ietf:params:xml:ns:yang:ietf-schedule : urn:ietf:params:xml:ns:yang:ietf-schedule
Registrant Contact: The IESG.
XML: N/A, the requested URI is an XML namespace.
~~~~
## The "YANG Module Names" Registry Registrant Contact:
: The IESG.
This document registers the following YANG module in the "YANG Module Names" XML:
: N/A; the requested URI is an XML namespace.
## The YANG Module Names Registry
This document has registered the following YANG module in the "YANG Module Names"
registry {{!RFC6020}}. registry {{!RFC6020}}.
~~~~ Name:
name: ietf-schedule : ietf-schedule
namespace: urn:ietf:params:xml:ns:yang:ietf-schedule
prefix: schedule Maintained by IANA:
maintained by IANA? N : N
reference: RFC XXXX
~~~~ Namespace:
: urn:ietf:params:xml:ns:yang:ietf-schedule
Prefix:
: schedule
Reference:
: RFC 9922
--- back --- back
# Examples of Scheduling Format Representation {#usage} # Examples of Scheduling Format Representation {#usage}
This section provides some examples to illustrate the use of the This section provides some examples to illustrate the use of the
period and recurrence formats defined in {{sec-schedule}}. The following period and recurrence formats defined in {{sec-schedule}}. The following
modules are used for illustration purposes and make examples verifiable: modules are used for illustration purposes and make examples verifiable:
~~~~ <!--[rfced] In Appendix A, should each example be listed in separate
sourcecode blocks? They are all currently contained within one block of
sourcecode.
-->
<!-- [rfced] FYI, the YANG examples (example-sch-usage-1 - 8.yang and
example-scheduled-backup.yang, example-scheduled-link-bandwidth.yang,
and example-sch-capacity-res.yang) each give errors and warnings from
pyang -ietf. Please confirm this is as expected.
-->
~~~~ yang
module example-sch-usage-1 { module example-sch-usage-1 {
yang-version 1.1; yang-version 1.1;
namespace "http://example.com/example-sch-usage-1"; namespace "http://example.com/example-sch-usage-1";
prefix "ex-schu-1"; prefix "ex-schu-1";
import ietf-schedule { import ietf-schedule {
prefix "schedule"; prefix "schedule";
} }
container generic-schedule-params { container generic-schedule-params {
skipping to change at line 1749 skipping to change at line 1956
uses schedule:icalendar-recurrence { uses schedule:icalendar-recurrence {
refine workweek-start { refine workweek-start {
default monday; default monday;
} }
} }
} }
} }
~~~~ ~~~~
For each example, only the message body is provided with For each example, only the message body is provided with
JSON used for encoding per the guidance in {{?RFC7951}}. JSON, which is used for encoding per the guidance in {{?RFC7951}}.
## The "generic-schedule-params" Grouping ## The "generic-schedule-params" Grouping
{{ex-0}} illustrates the example of a requested schedule that needs to start no earli er than {{ex-0}} illustrates the example of a requested schedule that needs to start no earli er than
08:00 AM, January 1, 2025 and end no later than 8:00 PM, January 31, 2025 (Beijing ti me). 08:00 AM, January 1, 2025 and end no later than 8:00 PM, January 31, 2025 (Beijing ti me).
Schedule requests that fail to meet the requirements are ignored by the system as ind icated by Schedule requests that fail to meet the requirements are ignored by the system, as in dicated by
"discard-action". "discard-action".
~~~~ ~~~~ json
{ {
"example-sch-usage-1:generic-schedule-params": { "example-sch-usage-1:generic-schedule-params": {
"time-zone-identifier": "China/Beijing", "time-zone-identifier": "China/Beijing",
"min-allowed-start": "2025-01-01T08:00:00", "min-allowed-start": "2025-01-01T08:00:00",
"max-allowed-end": "2025-01-31T20:00:00", "max-allowed-end": "2025-01-31T20:00:00",
"discard-action": "ietf-schedule:silently-discard" "discard-action": "ietf-schedule:silently-discard"
} }
} }
~~~~ ~~~~
{: #ex-0 title="Generic Parameters with 'max-allowed-end' for Schedule Validation"} {: #ex-0 title="Generic Parameters with 'max-allowed-end' for Schedule Validation"}
To illustrate the difference between "max-allowed-end" and "validity" parameters, To illustrate the difference between "max-allowed-end" and "validity" parameters,
{{ex-00}} shows the example of a requested schedule that needs to start no earlier th an {{ex-00}} shows the example of a requested schedule that needs to start no earlier th an
08:00 AM, January 1, 2025 (Beijing time). Schedule requests that fail to meet the 08:00 AM, January 1, 2025 (Beijing time). Schedule requests that fail to meet the
requirements are ignored by the system as indicated by "discard-action". The requirements are ignored by the system, as indicated by "discard-action". The
requested schedule may end after 8:00 PM, January 31, 2025, but any occurrences that are generated requested schedule may end after 8:00 PM, January 31, 2025, but any occurrences that are generated
after that time would not be considered as valid. after that time would not be considered as valid.
~~~~ ~~~~ json
{ {
"example-sch-usage-1:generic-schedule-params": { "example-sch-usage-1:generic-schedule-params": {
"time-zone-identifier": "China/Beijing", "time-zone-identifier": "China/Beijing",
"validity": "2025-01-31T20:00:00", "validity": "2025-01-31T20:00:00",
"min-allowed-start": "2025-01-01T08:00:00", "min-allowed-start": "2025-01-01T08:00:00",
"discard-action": "ietf-schedule:silently-discard" "discard-action": "ietf-schedule:silently-discard"
} }
} }
~~~~ ~~~~
{: #ex-00 title="Generic Parameters with 'validity' for Schedule Validation"} {: #ex-00 title="Generic Parameters with 'validity' for Schedule Validation"}
## The "period-of-time" Grouping ## The "period-of-time" Grouping
{{ex-1}} shows an example of a period that starts at 08:00:00 UTC, on January 1, 2 025 and ends at 18:00:00 UTC {{ex-1}} shows an example of a period that starts at 08:00:00 UTC on January 1, 20 25 and ends at 18:00:00 UTC
on December 31, 2027. on December 31, 2027.
~~~~ ~~~~ json
{ {
"example-sch-usage-2:period-of-time": { "example-sch-usage-2:period-of-time": {
"period-start": "2025-01-01T08:00:00Z", "period-start": "2025-01-01T08:00:00Z",
"period-end": "2027-12-31T18:00:00Z" "period-end": "2027-12-31T18:00:00Z"
} }
} }
~~~~ ~~~~
{: #ex-1 title="Simple Start/End Schedule"} {: #ex-1 title="Simple Start/End Schedule"}
An example of a period that starts at 08:00:00 UTC, on January 1, 2025 and lasts 1 5 days and An example of a period that starts at 08:00:00 UTC on January 1, 2025 and lasts 15 days and
5 hours and 20 minutes is encoded as shown in {{ex-2}}. 5 hours and 20 minutes is encoded as shown in {{ex-2}}.
~~~~ ~~~~ json
{ {
"example-sch-usage-2:period-of-time": { "example-sch-usage-2:period-of-time": {
"period-start": "2025-01-01T08:00:00Z", "period-start": "2025-01-01T08:00:00Z",
"duration": "P15DT05:20:00" "duration": "P15DT05:20:00"
} }
} }
~~~~ ~~~~
{: #ex-2 title="Simple Schedule with Duration"} {: #ex-2 title="Simple Schedule with Duration"}
An example of a period that starts at 2:00 A.M. in Los Angeles on November 19, An example of a period that starts at 2:00 AM in Los Angeles on November 19,
2025 and lasts 20 weeks is depicted in {{ex-3}}. 2025 and lasts 20 weeks is depicted in {{ex-3}}.
~~~~ ~~~~ json
{ {
"example-sch-usage-2:period-of-time": { "example-sch-usage-2:period-of-time": {
"period-start": "2025-11-19T02:00:00", "period-start": "2025-11-19T02:00:00",
"time-zone-identifier": "America/Los_Angeles", "time-zone-identifier": "America/Los_Angeles",
"duration": "P20W" "duration": "P20W"
} }
} }
~~~~ ~~~~
{: #ex-3 title="Simple Schedule with Time Zone Indication"} {: #ex-3 title="Simple Schedule with Time Zone Indication"}
## The "recurrence-basic" Grouping ## The "recurrence-basic" Grouping
{{ex-6}} indicates a recurrence of every 2 days which starts immediately and repea ts forever: {{ex-4}} indicates a recurrence of every 2 days, which starts immediately and repe ats forever:
~~~~ ~~~~ json
{ {
"example-sch-usage-3:recurrence-basic": { "example-sch-usage-3:recurrence-basic": {
"recurrence-description": "forever recurrence rule", "recurrence-description": "forever recurrence rule",
"frequency": "ietf-schedule:daily", "frequency": "ietf-schedule:daily",
"interval": 2 "interval": 2
} }
} }
~~~~ ~~~~
{: #ex-4 title="Simple Schedule with Recurrence"} {: #ex-4 title="Simple Schedule with Recurrence"}
## The "recurrence-utc" Grouping ## The "recurrence-utc" Grouping
{{ex-5}} indicates a recurrence from 8:00 AM to 9:00 AM every day, from {{ex-5}} indicates a recurrence from 8:00 AM to 9:00 AM every day, from
December 1 to December 31, 2025 in UTC: December 1 to December 31, 2025 in UTC:
~~~~ ~~~~ json
{ {
"example-sch-usage-4:recurrence-utc": { "example-sch-usage-4:recurrence-utc": {
"recurrence-first": { "recurrence-first": {
"start-time-utc": "2025-12-01T08:00:00Z", "start-time-utc": "2025-12-01T08:00:00Z",
"duration": 3600 "duration": 3600
}, },
"frequency": "ietf-schedule:daily", "frequency": "ietf-schedule:daily",
"interval": 1, "interval": 1,
"utc-until": "2025-12-31T23:59:59Z" "utc-until": "2025-12-31T23:59:59Z"
} }
} }
~~~~ ~~~~
{: #ex-5 title="Simple Schedule with Recurrence in UTC"} {: #ex-5 title="Simple Schedule with Recurrence in UTC"}
## The "recurrence-with-time-zone" Grouping ## The "recurrence-with-time-zone" Grouping
{{ex-6}} indicates a recurrence of every 2 hours for 10 occurrences, lasting {{ex-6}} indicates a recurrence of every 2 hours for 10 occurrences that
10 minutes, and starting at 3 p.m. on December 1, 2025 in New York: lasts 10 minutes and starts at 3 PM on December 1, 2025 in New York:
~~~~ ~~~~ json
{ {
"example-sch-usage-5:recurrence-with-time-zone": { "example-sch-usage-5:recurrence-with-time-zone": {
"recurrence-first": { "recurrence-first": {
"start-time": "2025-12-01T15:00:00", "start-time": "2025-12-01T15:00:00",
"duration": "PT00:10:00", "duration": "PT00:10:00",
"time-zone-identifier": "America/New_York" "time-zone-identifier": "America/New_York"
}, },
"frequency": "ietf-schedule:hourly", "frequency": "ietf-schedule:hourly",
"interval": 2, "interval": 2,
"count": 10 "count": 10
} }
} }
~~~~ ~~~~
{: #ex-6 title="Simple Schedule with Recurrence with Time Zone Indication"} {: #ex-6 title="Simple Schedule with Recurrence with Time Zone Indication"}
## The "recurrence-utc-with-periods" Grouping ## The "recurrence-utc-with-periods" Grouping
{{ex-7}} indicates a recurrence that occurs every two days starting at 9:00 AM {{ex-7}} indicates a recurrence that occurs every two days starting at 9:00 AM
and 3:00 PM for a duration of 30 minutes and 40 minutes respectively, and 3:00 PM for a duration of 30 minutes and 40 minutes, respectively,
from 2025-06-01 to 2025-06-30 in UTC: from 2025-06-01 to 2025-06-30 in UTC:
~~~~ <!--[rfced] We note that dates are formatted in different ways in
Appendix A. For example, "January 31, 2025" and "2025-06-01" are used
in Appendices A.1 and A.6, respectively. If these instances should be
consistent, please let us know which form you prefer.
Original:
Figure 10 illustrates the example of a requested schedule that needs
to start no earlier than 08:00 AM, January 1, 2025 and end no later
than 8:00 PM, January 31, 2025 (Beijing time).
...
Figure 18 indicates a recurrence that occurs every two days starting
at 9:00 AM and 3:00 PM for a duration of 30 minutes and 40 minutes
respectively, from 2025-06-01 to 2025-06-30 in UTC:
-->
~~~~ json
{ {
"example-sch-usage-6:recurrence-utc-with-periods": { "example-sch-usage-6:recurrence-utc-with-periods": {
"recurrence-first": { "recurrence-first": {
"start-time-utc": "2025-06-01T09:00:00Z" "start-time-utc": "2025-06-01T09:00:00Z"
}, },
"frequency": "ietf-schedule:daily", "frequency": "ietf-schedule:daily",
"interval": 2, "interval": 2,
"utc-until": "2025-06-30T23:59:59Z", "utc-until": "2025-06-30T23:59:59Z",
"period-timeticks": [ "period-timeticks": [
{ {
skipping to change at line 1920 skipping to change at line 2142
} }
] ]
} }
} }
~~~~ ~~~~
{: #ex-7 title="Example of Recurrence With Date Times"} {: #ex-7 title="Example of Recurrence With Date Times"}
## The "recurrence-time-zone-with-periods" Grouping ## The "recurrence-time-zone-with-periods" Grouping
{{ex-8}} indicates a recurrence that occurs every {{ex-8}} indicates a recurrence that occurs every
30 minutes and lasts for 15 minutes from 9:00 AM to 5:00 PM and an extra two occur rences 30 minutes and lasts for 15 minutes from 9:00 AM to 5:00 PM and two extra occurren ces
at 6:00 PM and 6:30 PM with each lasting for 20 minutes on 2025-12-01 (New York): at 6:00 PM and 6:30 PM with each lasting for 20 minutes on 2025-12-01 (New York):
~~~~ ~~~~ json
{ {
"example-sch-usage-7:recurrence-time-zone-with-periods": { "example-sch-usage-7:recurrence-time-zone-with-periods": {
"recurrence-first": { "recurrence-first": {
"start-time": "2025-12-01T09:00:00", "start-time": "2025-12-01T09:00:00",
"duration": "PT00:15:00", "duration": "PT00:15:00",
"time-zone-identifier": "America/New_York" "time-zone-identifier": "America/New_York"
}, },
"frequency": "ietf-schedule:minutely", "frequency": "ietf-schedule:minutely",
"interval": 30, "interval": 30,
"until": "2025-12-01T17:00:00Z", "until": "2025-12-01T17:00:00Z",
skipping to change at line 1951 skipping to change at line 2173
"duration": "PT00:20:00" "duration": "PT00:20:00"
} }
] ]
} }
} }
~~~~ ~~~~
{: #ex-8 title="Example of Advanced Recurrence Schedule"} {: #ex-8 title="Example of Advanced Recurrence Schedule"}
## The "icalendar-recurrence" Grouping ## The "icalendar-recurrence" Grouping
{{ex-9}} indicates 10 occurrences that occur at {{ex-9}} indicates 10 occurrences at
8:00 AM (EST), every last Saturday of the month starting in January 2024: 8:00 AM (EST) every last Saturday of the month starting in January 2024:
~~~~ ~~~~ json
{ {
"example-sch-usage-8:icalendar-recurrence": { "example-sch-usage-8:icalendar-recurrence": {
"recurrence-first": { "recurrence-first": {
"start-time": "2024-01-27T08:00:00", "start-time": "2024-01-27T08:00:00",
"time-zone-identifier": "America/New_York" "time-zone-identifier": "America/New_York"
}, },
"frequency": "ietf-schedule:monthly", "frequency": "ietf-schedule:monthly",
"count": 10, "count": 10,
"byday": [ "byday": [
{ {
skipping to change at line 1977 skipping to change at line 2199
], ],
"weekday": "saturday" "weekday": "saturday"
} }
] ]
} }
} }
~~~~ ~~~~
{: #ex-9 title="Simple iCalendar Recurrence"} {: #ex-9 title="Simple iCalendar Recurrence"}
{{ex-10}} is an example of a recurrence that occurs on the last {{ex-10}} is an example of a recurrence that occurs on the last
workday of the month until December 25, 2025, from January 1, 2025: workday of the month until December 25, 2025, starting January 1, 2025:
~~~~ ~~~~ json
{ {
"example-sch-usage-8:icalendar-recurrence": { "example-sch-usage-8:icalendar-recurrence": {
"recurrence-first": { "recurrence-first": {
"start-time": "2025-01-01" "start-time": "2025-01-01"
}, },
"frequency": "ietf-schedule:monthly", "frequency": "ietf-schedule:monthly",
"until": "2025-12-25", "until": "2025-12-25",
"byday": [ "byday": [
{ {
"weekday": "monday" "weekday": "monday"
skipping to change at line 2013 skipping to change at line 2235
], ],
"bysetpos": [ "bysetpos": [
-1 -1
] ]
} }
} }
~~~~ ~~~~
{: #ex-10 title="Example of Advanced iCalendar Recurrence"} {: #ex-10 title="Example of Advanced iCalendar Recurrence"}
{{ex-11}} indicates a recurrence that occurs every 20 {{ex-11}} indicates a recurrence that occurs every 20
minutes from 9:00 AM to 4:40 PM (UTC), with the occurrence starting at 10:20 AM minutes from 9:00 AM to 4:40 PM (UTC), with the exclusion of the
being excluded on 2025-12-01: occurrence starting at 10:20 AM on 2025-12-01:
~~~~ ~~~~ json
{ {
"example-sch-usage-8:icalendar-recurrence": { "example-sch-usage-8:icalendar-recurrence": {
"recurrence-first": { "recurrence-first": {
"start-time": "2025-12-01T09:00:00Z" "start-time": "2025-12-01T09:00:00Z"
}, },
"until": "2025-12-01T16:40:00Z", "until": "2025-12-01T16:40:00Z",
"frequency": "ietf-schedule:minutely", "frequency": "ietf-schedule:minutely",
"byminute": [ "byminute": [
0, 0,
20, 20,
skipping to change at line 2050 skipping to change at line 2272
"2025-12-01T10:20:00Z" "2025-12-01T10:20:00Z"
] ]
} }
} }
~~~~ ~~~~
{: #ex-11 title="Example of Advanced iCalendar Recurrence with Exceptions"} {: #ex-11 title="Example of Advanced iCalendar Recurrence with Exceptions"}
## The "schedule-status" Grouping ## The "schedule-status" Grouping
{{ex-12}} indicates the scheduled recurrence status of {{ex-11}} at the time {{ex-12}} indicates the scheduled recurrence status of {{ex-11}} at the time
of 12:15 PM, 2025-12-01 (UTC): of 12:15 PM on 2025-12-01 (UTC):
~~~~ ~~~~ json
{ {
"example-sch-usage-1:schedule-status": { "example-sch-usage-1:schedule-status": {
"state": "ietf-schedule:enabled", "state": "ietf-schedule:enabled",
"version": 1, "version": 1,
"schedule-type": "ietf-schedule:recurrence", "schedule-type": "ietf-schedule:recurrence",
"counter": 9, "counter": 9,
"last-occurrence": [ "last-occurrence": [
"2025-12-01T12:00:00Z" "2025-12-01T12:00:00Z"
], ],
"upcoming-occurrence": [ "upcoming-occurrence": [
"2025-12-01T12:20:00Z" "2025-12-01T12:20:00Z"
] ]
} }
} }
~~~~ ~~~~
{: #ex-12 title="Example of a Schedule Status"} {: #ex-12 title="Example of a Schedule Status"}
At the time of 12:15 PM, 2025-12-01 (UTC), the recurring event occurred at At the time of 12:15 PM on 2025-12-01 (UTC), the recurring event occurred at
(note that occurrence at 10:20 AM is excluded): (note that the occurrence at 10:20 AM is excluded):
9:00, 9:20, 9:40, 10:00, 10:40, 11:00, 11:20, 11:40, 12:00. 9:00, 9:20, 9:40, 10:00, 10:40, 11:00, 11:20, 11:40, and 12:00.
The last occurrence was at 12:00, the upcoming one is at 12:20. The last occurrence was at 12:00, and the upcoming one is at 12:20.
# Examples of Using/Extending the "ietf-schedule" Module {#sec-ext} # Examples of Using/Extending the "ietf-schedule" Module {#sec-ext}
This non-normative section shows two examples for how the "ietf-schedule" module This non-normative section shows two examples for how the "ietf-schedule" module
can be used or extended for scheduled events or attributes based on date and time. can be used or extended for scheduled events or attributes based on date and time.
## Example: Schedule Tasks to Execute Based on a Recurrence Rule {#features} ## Example: Schedule Tasks to Execute Based on a Recurrence Rule {#features}
Scheduled tasks can be used to execute specific actions based on certain recurrenc e rules (e.g., Scheduled tasks can be used to execute specific actions based on certain recurrenc e rules (e.g.,
every Friday at 8:00 AM). The following example module which "uses" the "icalendar every Friday at 8:00 AM). The following example module, which "uses" the "icalenda
-recurrence" r-recurrence"
grouping from "ietf-schedule" module shows how a scheduled task could be defined grouping from the "ietf-schedule" module, shows how a scheduled task could be defi
ned
with different features used for options. with different features used for options.
~~~~ ~~~~ yang
module example-scheduled-backup { module example-scheduled-backup {
yang-version 1.1; yang-version 1.1;
namespace "http://example.com/example-scheduled-backup"; namespace "http://example.com/example-scheduled-backup";
prefix "ex-scback"; prefix "ex-scback";
import ietf-inet-types { import ietf-inet-types {
prefix "inet"; prefix "inet";
} }
import ietf-schedule { import ietf-schedule {
prefix "schedule"; prefix "schedule";
} }
organization organization
"Example, Inc."; "Example, Inc.";
contact contact
"Support at example.com"; "Support at example.com";
description description
"Example of a module defining a scheduled based backup "Example of a module defining a scheduled-based backup
operation."; operation.";
revision "2023-01-19" { revision "2023-01-19" {
description description
"Initial Version."; "Initial version.";
reference reference
"RFC XXXX: A YANG Data Model for Scheduling."; "RFC 9922: A YANG Data Model for Scheduling.";
} }
container scheduled-backup-tasks { container scheduled-backup-tasks {
description description
"A container for backing up all current running configuration "A container for backing up all current running configurations
on the device."; on the device.";
list tasks { list tasks {
key "task-id"; key "task-id";
description description
"The list of backing up tasks on this device."; "The list of backing up tasks on this device.";
leaf task-id { leaf task-id {
type string; type string;
description description
"The task identifier that uniquely identifies a scheduled "The task identifier that uniquely identifies a scheduled
backup task."; backup task.";
} }
choice local-or-remote { choice local-or-remote {
description description
"Specifies whether the configuration to be backed up is "Specifies whether the configuration to be backed up is
local or remote."; local or remote.";
case local { case local {
description description
"Configuration parameters for backing up of local "Configuration parameters for the backing up of local
devices."; devices.";
leaf local { leaf local {
type empty; type empty;
description description
"The parameter specifies the configuration to be "The parameter specifies the configuration to be
backed up is on the local device."; backed up is on the local device.";
} }
} }
case remote { case remote {
description description
skipping to change at line 2163 skipping to change at line 2385
description description
"The parameter specifies the remote device domain "The parameter specifies the remote device domain
name."; name.";
} }
} }
} }
container basic-recurrence-schedules { container basic-recurrence-schedules {
if-feature schedule:basic-recurrence; if-feature schedule:basic-recurrence;
description description
"Basic recurrence schedule specification, only applies when "Basic recurrence schedule specification, which only
schedule:basic-recurrence feature is supported."; applies when the schedule:basic-recurrence feature
is supported.";
leaf schedule-id { leaf schedule-id {
type string; type string;
description description
"The schedule identifier for this recurrence rule."; "The schedule identifier for this recurrence rule.";
} }
uses schedule:recurrence-basic { uses schedule:recurrence-basic {
refine frequency { refine frequency {
mandatory true; mandatory true;
} }
refine interval { refine interval {
default 1; default 1;
} }
} }
} }
container icalendar-recurrence-schedules { container icalendar-recurrence-schedules {
if-feature schedule:icalendar-recurrence; if-feature schedule:icalendar-recurrence;
description description
"Basic recurrence schedule specification, only applies when "Basic recurrence schedule specification, which only
schedule:icalendar-recurrence feature is supported."; applies when the schedule:icalendar-recurrence feature
is supported.";
leaf schedule-id { leaf schedule-id {
type string; type string;
description description
"The schedule identifier for this recurrence rule."; "The schedule identifier for this recurrence rule.";
} }
uses schedule:icalendar-recurrence { uses schedule:icalendar-recurrence {
refine workweek-start { refine workweek-start {
default monday; default monday;
} }
} }
} }
} }
list schedule-set { list schedule-set {
key "schedule-name"; key "schedule-name";
description description
"The list of schedule status for the backup tasks."; "Schedule status list for the backup tasks.";
uses schedule:schedule-status-with-name; uses schedule:schedule-status-with-name;
} }
} }
} }
~~~~ ~~~~
## Example: Schedule Network Properties to Change Based on Date and Time {#augments} ## Example: Schedule Network Properties to Change Based on Date and Time {#augments}
Network properties may change over a specific period of time or based on a Network properties may change over a specific period of time or based on a
recurrence rule, e.g., {{?RFC9657}}. recurrence rule, e.g., {{?RFC9657}}.
The following example module which augments the "recurrence-utc-with-periods" The following example module, which augments the "recurrence-utc-with-periods"
grouping from "ietf-schedule" module shows how a scheduled attribute grouping from the "ietf-schedule" module, shows how a scheduled attribute
could be defined. could be defined.
~~~~ <!--[rfced] The example module in Appendix B references RFC 8345 but
no corresponding reference entry exists. May we add RFC 8345 under the
Informative References section and update the running text as follows?
Original:
The following example module which augments the
"recurrence-utc-with-periods" grouping from "ietf-schedule" module
shows how a scheduled attribute could be defined.
Perhaps:
The following example module, which augments the
"recurrence-utc-with-periods" grouping from "ietf-schedule" module,
shows how a scheduled attribute could be defined. Note that
[RFC8345] and this document are referenced in the module.
-->
~~~~ yang
module example-scheduled-link-bandwidth { module example-scheduled-link-bandwidth {
yang-version 1.1; yang-version 1.1;
namespace "http://example.com/example-scheduled-link-bandwidth"; namespace "http://example.com/example-scheduled-link-bandwidth";
prefix "ex-scattr"; prefix "ex-scattr";
import ietf-network { import ietf-network {
prefix "nw"; prefix "nw";
reference reference
"RFC 8345: A YANG Data Model for Network Topologies"; "RFC 8345: A YANG Data Model for Network Topologies";
} }
import ietf-schedule { import ietf-schedule {
prefix "schedule"; prefix "schedule";
reference reference
"RFC XXXX: A YANG Data Model for Scheduling"; "RFC 9922: A YANG Data Model for Scheduling";
} }
organization organization
"Example, Inc."; "Example, Inc.";
contact contact
"Support at example.com"; "Support at example.com";
description description
"Example of a module defining a scheduled link bandwidth."; "Example of a module defining a scheduled link bandwidth.";
revision "2023-01-19" { revision "2023-01-19" {
description description
"Initial Version."; "Initial version.";
reference reference
"RFC XXXX: A YANG Data Model for Scheduling."; "RFC 9922: A YANG Data Model for Scheduling";
} }
grouping link-bandwidth-grouping { grouping link-bandwidth-grouping {
description description
"Grouping of the link bandwidth definition."; "Grouping of the link bandwidth definition.";
leaf scheduled-bandwidth { leaf scheduled-bandwidth {
type uint64; type uint64;
units "Kbps"; units "Kbps";
description description
"Bandwidth values, expressed in kilobits per second."; "Bandwidth values, expressed in kilobits per second.";
skipping to change at line 2283 skipping to change at line 2523
leaf destination-node { leaf destination-node {
type nw:node-id; type nw:node-id;
description description
"Indicates the source node identifier."; "Indicates the source node identifier.";
} }
leaf default-bandwidth { leaf default-bandwidth {
type uint64; type uint64;
units "Kbps"; units "Kbps";
description description
"Bandwidth value used for perdiods that don't match "Bandwidth value used for periods that don't match
a schedule."; a schedule.";
} }
choice time-variant-type { choice time-variant-type {
description description
"Controls the schedule type."; "Controls the schedule type.";
case period { case period {
uses schedule:period-of-time; uses schedule:period-of-time;
} }
case recurrence { case recurrence {
uses schedule:recurrence-utc-with-periods { uses schedule:recurrence-utc-with-periods {
augment "period-timeticks" { augment "period-timeticks" {
description description
"Specifies the attributes inside each "Specifies the attributes inside each
period-timeticks entry."; 'period-timeticks' entry.";
uses link-bandwidth-grouping; uses link-bandwidth-grouping;
} }
} }
} }
} }
} }
} }
} }
~~~~ ~~~~
{{ex-13}} shows a configuration example of a link's bandwidth that is {{ex-13}} shows a configuration example in XML {{W3C.XML1.0}} of a link's bandwidth that is
scheduled between 2025-12-01 0:00 UTC to the end of 2025-12-31 with a daily scheduled between 2025-12-01 0:00 UTC to the end of 2025-12-31 with a daily
schedule. In each day, the bandwidth value is scheduled to be 500 Kbps between schedule. In each day, the bandwidth value is scheduled to be 500 Kbps between
1:00 AM to 6:00 AM and 800 Kbps between 10:00 PM to 11:00 PM. The bandwidth 1:00 AM to 6:00 AM and 800 Kbps between 10:00 PM to 11:00 PM. The bandwidth
value that is not covered by the period above is 1000 Kbps. value that is not covered by the period above is 1000 Kbps.
~~~~ <!--[rfced] FYI, a normative reference to the XML specification has
been added because this document contains XML.
See the IESG statement on "Guidelines for the Use of Formal
Languages in IETF Specifications"
(https://ietf.org/blog/guidelines-use-formal-languages-ietf-specifications/) -
specifically "The use of a language requires a reference to the
specification for that language. This reference is normative, and
needs to fulfil the usual requirements for normative references
(Section 7 of RFC 2026)." Please review where the XML specification
is cited and let us know if you prefer otherwise.
Original:
Figure 24 shows a configuration example of a link's bandwidth that is
scheduled between 2025-12-01 0:00 UTC to the end of 2025-12-31 with a
daily schedule.
Current:
Figure 24 shows a configuration example in XML [W3C.XML1.0]
of a link's bandwidth that is scheduled between 2025-12-01 0:00 UTC
to the end of 2025-12-31 with a daily schedule.
Normative Reference Entry:
[W3C.XML1.0]
Bray, T., Ed., Paoli, J., Ed., Sperberg-McQueen, C.M., Ed., Maler,
E., Ed., and F. Yergeau, Ed., "Extensible Markup Language (XML)
1.0 (Fifth Edition)", W3C Recommendation, 26 November 2008,
<https://www.w3.org/TR/2008/REC-xml-20081126/>.
-->
~~~ xml
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<link-attributes <link-attributes
xmlns=http://example.com/example-scheduled-link-bandwidth xmlns="http://example.com/example-scheduled-link-bandwidth"
xmlns:schedule="urn:ietf:params:xml:ns:yang:ietf-schedule"> xmlns:schedule="urn:ietf:params:xml:ns:yang:ietf-schedule">
<link> <link>
<source-node>ne1</source-node> <source-node>ne1</source-node>
<destination-node>ne2</destination-node> <destination-node>ne2</destination-node>
<default-bandwidth>1000</default-bandwidth> <default-bandwidth>1000</default-bandwidth>
<recurrence-first> <recurrence-first>
<utc-start-time>2025-12-01T01:00:00Z</utc-start-time> <utc-start-time>2025-12-01T01:00:00Z</utc-start-time>
</recurrence-first> </recurrence-first>
<frequency>schedule:daily</frequency> <frequency>schedule:daily</frequency>
<utc-until>2025-12-31T23:59:59Z</utc-until> <utc-until>2025-12-31T23:59:59Z</utc-until>
skipping to change at line 2341 skipping to change at line 2610
<period-end>2160000</period-end> <period-end>2160000</period-end>
<scheduled-bandwidth>500</scheduled-bandwidth> <scheduled-bandwidth>500</scheduled-bandwidth>
</period-timeticks> </period-timeticks>
<period-timeticks> <period-timeticks>
<period-start>7920000</period-start> <period-start>7920000</period-start>
<period-end>8280000</period-end> <period-end>8280000</period-end>
<scheduled-bandwidth>800</scheduled-bandwidth> <scheduled-bandwidth>800</scheduled-bandwidth>
</period-timeticks> </period-timeticks>
</link> </link>
</link-attributes> </link-attributes>
~~~~ ~~~
{: #ex-13 title="Example of Scheduled Link's Bandwidth"} {: #ex-13 title="Example of Scheduled Link's Bandwidth"}
# Examples of Using "ietf-schedule" Module for Scheduled Use of Resources Framework { #ex-framework} # Examples of Using the "ietf-schedule" Module for Scheduled Use of Resources Framewo rk {#ex-framework}
This section exemplifies how the architecture for supporting scheduled This section exemplifies how the architecture for supporting scheduled
reservation of Traffic Engineering (TE) resources in {{?RFC8413}} might leverage t he "period-of-time" reservation of Traffic Engineering (TE) resources in {{?RFC8413}} might leverage t he "period-of-time"
grouping defined in the "ietf-schedule" module to implement scheduled use of grouping defined in the "ietf-schedule" module to implement scheduled use of
resources. resources.
The following example module shows how a scheduled link capacity reservation The following example module shows how a scheduled link capacity reservation
could be defined. could be defined.
~~~~ ~~~~ yang
module example-sch-capacity-res { module example-sch-capacity-res {
yang-version 1.1; yang-version 1.1;
namespace http://example.com/example-sch-capacity-res; namespace "http://example.com/example-sch-capacity-res";
prefix "ex-schecaparev"; prefix "ex-schecaparev";
import ietf-network-topology { import ietf-network-topology {
prefix "nt"; prefix "nt";
} }
import ietf-schedule { import ietf-schedule {
prefix "schedule"; prefix "schedule";
} }
skipping to change at line 2388 skipping to change at line 2657
type uint64; type uint64;
units "Mbps"; units "Mbps";
} }
uses schedule:period-of-time; uses schedule:period-of-time;
} }
} }
} }
~~~~ ~~~~
{{Section 4 of ?RFC8413}} defines the reference architecture for scheduled use {{Section 4 of ?RFC8413}} defines the reference architecture for scheduled use
of resources, the service requester sends a request to a Path Computation Element of resources. The service requester sends a request to a Path Computation Element
(PCE) and includes the (PCE) and includes the
parameters of the Label Switched Path (LSP) that the requester wishes to supply, t parameters of the Label Switched Path (LSP) that the requester wishes to supply. T
he configuration he configuration
example to provide the scheduled resource is shown in {{ex-14}}. example to provide the scheduled resource is shown in {{ex-14}}.
~~~~ ~~~~ xml
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<link-capability-reservations <link-capability-reservations
xmlns=http://example.com/example-sch-capacity-res xmlns="http://example.com/example-sch-capacity-res"
xmlns:schedule="urn:ietf:params:xml:ns:yang:ietf-schedule"> xmlns:schedule="urn:ietf:params:xml:ns:yang:ietf-schedule">
<scheduled-link-capacity> <scheduled-link-capacity>
<schedule-id>1</schedule-id> <schedule-id>1</schedule-id>
<link-id>1-2-1</link-id> <link-id>1-2-1</link-id>
<reserved-capability>500</reserved-capability> <reserved-capability>500</reserved-capability>
<period-start>2025-03-10T08:00:00Z</period-start> <period-start>2025-03-10T08:00:00Z</period-start>
<period-end>2025-03-10T09:00:00Z</period-end> <period-end>2025-03-10T09:00:00Z</period-end>
</scheduled-link-capacity> </scheduled-link-capacity>
<scheduled-link-capacity> <scheduled-link-capacity>
<schedule-id>2</schedule-id> <schedule-id>2</schedule-id>
skipping to change at line 2425 skipping to change at line 2694
<period-start>2025-04-01T09:00:00Z</period-start> <period-start>2025-04-01T09:00:00Z</period-start>
<period-end>2025-04-01T23:59:59Z</period-end> <period-end>2025-04-01T23:59:59Z</period-end>
</scheduled-link-capacity> </scheduled-link-capacity>
</link-capability-reservations> </link-capability-reservations>
~~~~ ~~~~
{: #ex-14 title="Example of Scheduled Link's Bandwidth Reservation"} {: #ex-14 title="Example of Scheduled Link's Bandwidth Reservation"}
# Acknowledgments # Acknowledgments
{:numbered="false"} {:numbered="false"}
This work is derived from the {{?I-D.ietf-opsawg-ucl-acl}}. There is a desire This work is derived from {{?I-D.ietf-opsawg-ucl-acl}}. There is a desire
from the OPSAWG to see this model be separately defined for wide use in scheduling from the OPSAWG to see this module separately defined for wide use in scheduling c
context. ontext.
Thanks to Adrian Farrel, Wei Pan, Tianran Zhou, Joe Clarke, Steve Baillargeon, Dhr uv Dhody, Robert Wilton, and Italo Busi Thanks to {{{Adrian Farrel}}}, {{{Wei Pan}}}, {{{Tianran Zhou}}}, {{{Joe Clarke}}} , {{{Steve Baillargeon}}}, {{{Dhruv Dhody}}}, {{{Robert Wilton}}}, and {{{Italo Busi} }}
for their valuable comments and inputs to this work. for their valuable comments and inputs to this work.
Many thanks to the authors of {{?I-D.ietf-tvr-schedule-yang}}, {{?I-D.ietf-opsawg- scheduling-oam-tests}}, and {{?I-D.ietf-netmod-eca-policy}} Many thanks to the authors of {{?I-D.ietf-tvr-schedule-yang}}, {{?I-D.ietf-opsawg- scheduling-oam-tests}}, and {{?I-D.ietf-netmod-eca-policy}}
for the constructive discussion during IETF#118. for the constructive discussion during IETF#118.
Other related efforts were explored in the past, e.g., {{?I-D.liu-netmod-yang-sche dule}}. Other related efforts were explored in the past, e.g., {{?I-D.liu-netmod-yang-sche dule}}.
Thanks to Reshad Rahman for the great YANG Doctors review, Mahesh Jethanandani for Thanks to {{{Reshad Rahman}}} for the great YANG Doctors review, {{{Mahesh Jethana
the AD review, Per Andersson for the OPSDIR review, ndani}}} for the AD review, {{{Per Andersson}}} for the OPSDIR review,
Peter Yee for genart review, and Acee Lindem for the rtgdir review. {{{Peter Yee}}} for the GENART review, and {{{Acee Lindem}}} for the RTGDIR review
.
Thanks to Éric Vyncke, Erik Kline, and Mike Bishop for the IESG review. Thanks to {{{Éric Vyncke}}}, {{{Erik Kline}}}, and {{{Mike Bishop}}} for the IESG
review.
<!-- [rfced] Please review the language set for each instance of sourcecode
in the MD file to ensure correctness. If the current list of preferred
values for languages
(https://www.rfc-editor.org/rpc/wiki/doku.php?id=sourcecode-types)
does not contain an applicable language, then feel free to let us know.
Also, it is acceptable to leave the language not set.
-->
<!-- [rfced] RFC 6991 has been obsoleted by RFC 9911. May we replace RFC
6991 with RFC 9911? If yes, this will include updating the references in the
YANG module.
-->
<!-- [rfced] Please review the "Inclusive Language" portion of the online
Style Guide <https://www.rfc-editor.org/styleguide/part2/#inclusive_language>
and let us know if any changes are needed. Updates of this nature typically
result in more precise language, which is helpful for readers.
Note that our script did not flag any words in particular, but this should
still be reviewed as a best practice.
-->
 End of changes. 192 change blocks. 
269 lines changed or deleted 540 lines changed or added

This html diff was produced by rfcdiff 1.48.