Support of Versioning in
YANG Notifications SubscriptionSwisscomBinzring 17Zurich8045Switzerlandthomas.graf@swisscom.comHuaweibenoit.claise@huawei.comINSA-LyonLyonFrancealex.huang-feng@insa-lyon.frThis document extends the YANG notifications subscription mechanism
to specify the YANG module semantic version at the subscription. Then, a
new extension with new metadata of the YANG push update notification
header is proposed.The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" in this document are to be interpreted as described in BCP 14
when, and only when,
they appear in all capitals, as shown here.In order to process the received YANG push notification messages
described in section 3.7 of at the YANG push
receiver, a semantic reference to the YANG module and the XPath or
subtree is needed to determine the data types for each field and which
part of the YANG module the metrics are expose from.This specification applies to the YANG push configured subscriptions
defined in Section 2.5 of , where a publisher is
configured to stream notification out of band, as opposed to dynamic
subscriptions defined in Section 2.4 of , where
the subscriber can initiate and modify the subscription dynamically
in-band. In the latter case, the subscriber knows already all the
subscriber YANG-related information, which it has to know in order to
configure the subscription.This semantic reference is available during the subscription period
described in Section 3.6 of where for each
subscription a locally unique subscription ID described in Section 4.3.2
of is being issued and streamed as metadata
with the notification message in the YANG push message header. This
implies that the YANG receiver needs to lookup the subscription
inventory for a subscription ID in each notification message to
determine the YANG module name, namespace, and filter definitions.The semantics can change between different YANG module revisions. The
YANG module version statement is specified in Section 7.1.2 of and states that the newer revision needs to be
backward compatible to the previous revision. Section 3.1 of specifies that newer
semantic versions introduced in MAY not be backward compatible to
the previous version when indicated with non-backwards-compatible
keyword.The YANG notifications subscription mechanism defined in does not allow to specify the YANG module revision.
When a network node is upgraded, the subscribed YANG module revision MAY
have updated and might, consequently, break the data processing pipeline
since the YANG push receiver may not be aware of this change.This documents extends the current YANG notifications subscription
mechanism to allow to subscribe to a specific revision or latest
semantic version to which the YANG module version needs to be backward
compatible to and advertises its specific YANG module revision inband.
Besides the existing Subscription ID, the YANG module name, namespace,
revision and filtering metadata is added to the YANG push notification
header to lift the YANG push receiver need to lookup the subscription
inventory information.The YANG notifications subscription OPTIONALLY can be restricted to
the following YANG module revision for future capabilities:
latest:
Restricts the subscription to the latest YANG module
revision.
revision:
Restricts the subscription to a specific YANG module revision.
Example 2014-05-08.
latest-compatible-semversion:
Restricts the subscription to the latest compatible YANG module
semantic version referenced to. Example 2.0.0.
If nothing is specified, latest YANG module version is implied.Along with the subscribed content, besides the Subcription ID, the
following metadata objects are part of a "push-update" or
"push-change-update" notification.
module:
Describes the YANG module name for the related streamed
content.
namespace:
Describes the YANG module namespace as specified in Section 7.1.3
of for the related streamed content.
revision:
Describes the YANG module revision as specified in Section 7.1.2
of for the related streamed content.
revision-label:
Describes the YANG module semantic version as specified in for the related streamed
content.
datastore-xpath-filter:
Describes the YANG module xpath filter as specified in Section 6.4
of for the related streamed content.
datastore-subtree-filter:
Describes the YANG module subtree filter as specified in Section 6
of for the related streamed content.
Figure 1 provides an example of a notification message with the YANG
module name, revision, revision label and datastore-xpath-filter for a
subscription tracking the operational status of a single Ethernet
interface (per ). This notification message is
encoded XML over the Network
Configuration Protocol (NETCONF) as per .Figure 2 provides an example of a JSON encoded, , notification message over HTTPS-based or UDP-based transport for the same
subscription.This YANG module augments the "ietf-yang-push" module to add
subcription metadata into the "push-update" and "push-change-update"
notification and the ability to define the "revision" and
"revision-label" in the "establish-subscription" and
"modify-subscription" in the datastore push subscription.The YANG module has six leaves augmenting the model of YANG-push.The security considerations for the YANG notifications subscription
mechanism are described in . This documents adds
no additional security considerations.This document has no IANA actions.The authors would like to thank xxx for their review and valuable
comments.Extensible Markup Language (XML) 1.0 (Fifth Edition)World Wide Web Consortium Recommendation
REC-xml-20081126