Skip to main content

Concluded WG Forwarding and Control Element Separation (forces)

Group history

Date By Action
2015-03-24 Cindy Morgan State changed to Concluded from Active
2015-02-27 Stephanie McCammon sent scheduled notification for IETF-92
2015-01-04 Jamal Hadi Salim Changed milestone "Request for publication of parallelization LFBs", resolved as "Done"
2015-01-04 Jamal Hadi Salim Changed milestone "Request for Publication of Standards Track document specifying protocol changes", resolved as "Done"
2015-01-04 Jamal Hadi Salim Changed milestone "Request for Publication of Standards Track document specifying model changes", resolved as "Done"
2014-06-23 Stephanie McCammon sent scheduled notification for IETF-90
2013-05-16 Cindy Morgan Chairs changed to Damascane Joachimpillai, Jamal Hadi Salim from Jamal Hadi Salim
2013-05-16 Cindy Morgan Tech Advisors changed to Joel Halpern from
2013-04-23 Cindy Morgan
Internet Engineering Task Force (IETF)                        A. Bierman
Request for Comments: 8525        …
Internet Engineering Task Force (IETF)                        A. Bierman
Request for Comments: 8525                                    YumaWorks
Obsoletes: 7895                                            M. Bjorklund
Category: Standards Track                                Tail-f Systems
ISSN: 2070-1721                                        J. Schoenwaelder
                                                      Jacobs University
                                                              K. Watsen
                                                        Watsen Networks
                                                              R. Wilton
                                                          Cisco Systems
                                                              March 2019

                              YANG Library

Abstract

  This document describes a YANG library that provides information
  about the YANG modules, datastores, and datastore schemas used by a
  network management server.  Simple caching mechanisms are provided to
  allow clients to minimize retrieval of this information.  This
  version of the YANG library supports the Network Management Datastore
  Architecture (NMDA) by listing all datastores supported by a network
  management server and the schema that is used by each of these
  datastores.

  This document obsoletes RFC 7895.

Status of This Memo

  This is an Internet Standards Track document.

  This document is a product of the Internet Engineering Task Force
  (IETF).  It represents the consensus of the IETF community.  It has
  received public review and has been approved for publication by the
  Internet Engineering Steering Group (IESG).  Further information on
  Internet Standards is available in Section 2 of RFC 7841.

  Information about the current status of this document, any errata,
  and how to provide feedback on it may be obtained at
  https://www.rfc-editor.org/info/rfc8525.

Bierman, et al.              Standards Track                    [Page 1]
RFC 8525                      YANG Library                    March 2019

Copyright Notice

  Copyright (c) 2019 IETF Trust and the persons identified as the
  document authors.  All rights reserved.

  This document is subject to BCP 78 and the IETF Trust's Legal
  Provisions Relating to IETF Documents
  (https://trustee.ietf.org/license-info) in effect on the date of
  publication of this document.  Please review these documents
  carefully, as they describe your rights and restrictions with respect
  to this document.  Code Components extracted from this document must
  include Simplified BSD License text as described in Section 4.e of
  the Trust Legal Provisions and are provided without warranty as
  described in the Simplified BSD License.

Table of Contents

  1. Introduction ....................................................3
      1.1. Terminology ................................................4
  2. Objectives ......................................................5
  3. YANG Library Data Model .........................................6
  4. YANG Library YANG Module ........................................8
  5. IANA Considerations ............................................20
  6. Security Considerations ........................................21
  7. References .....................................................22
      7.1. Normative References ......................................22
      7.2. Informative References ....................................23
  Appendix A.  Summary of Changes from RFC 7895 .....................25
  Appendix B.  Example YANG Library Instance for a Basic Server .....25
  Appendix C.  Example YANG Library Instance for an Advanced Server .27
  Authors' Addresses ................................................32

Bierman, et al.              Standards Track                    [Page 2]
RFC 8525                      YANG Library                    March 2019

1.  Introduction

  There is a need for a standard mechanism to expose which YANG modules
  [RFC7950], datastores [RFC8342], and datastore schemas [RFC8342] are
  in use by a network management server.

  This document defines the YANG module "ietf-yang-library" that
  provides this information.  This version of the YANG library is
  compatible with the Network Management Datastore Architecture (NMDA)
  [RFC8342].  The previous version of the YANG library, defined in
  [RFC7895], is not compatible with the NMDA since it assumes that all
  datastores have exactly the same schema.  This is not necessarily
  true in the NMDA since dynamic configuration datastores may have
  their own datastore schema.  Furthermore, the operational state
  datastore may support non-configurable YANG modules in addition to
  the YANG modules supported by conventional configuration datastores.

  The old YANG library definitions have been retained (for backwards-
  compatibility reasons), but the definitions have been marked as
  deprecated.  For backwards compatibility, an NMDA-supporting server
  SHOULD populate the deprecated "/modules-state" tree in a backwards-
  compatible manner.  The new "/yang-library" tree will be ignored by
  legacy clients but will provide all the data needed for NMDA-aware
  clients (which will ignore the "/modules-state" tree).  The
  recommended approach to populate "/modules-state" is to report the
  YANG modules with "config true" data nodes that are configurable via
  conventional configuration datastores and the YANG modules with
  "config false" data nodes that are returned via a Network
  Configuration Protocol (NETCONF) <get> operation or equivalent.

  The YANG library information can be different on every server, and it
  can change at runtime or across a server reboot.  If a server
  implements multiple network management protocols to access the
  server's datastores, then each such protocol may have its own
  conceptual instantiation of the YANG library.

  If a large number of YANG modules are utilized by a server, then the
  YANG library contents can be relatively large.  Since the YANG
  library contents change very infrequently, it is important that
  clients be able to cache the YANG library contents and easily
  identify whether their cache is out of date.

Bierman, et al.              Standards Track                    [Page 3]
RFC 8525                      YANG Library                    March 2019

1.1.  Terminology

  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 [RFC2119] [RFC8174] when, and only when, they appear in all
  capitals, as shown here.

  The following terms are defined in [RFC7950]:

  o  module

  o  submodule

  o  data node

  This document uses the phrase "implement a module" as defined in
  Section 5.6.5 of [RFC7950].

  The following terms are defined in [RFC8342]:

  o  datastore

  o  datastore schema

  o  configuration

  o  conventional configuration datastore

  o  operational state

  o  operational state datastore

  o  dynamic configuration datastore

  o  client

  o  server

  The following terms are used within this document:

  o  YANG library: A collection of YANG modules, submodules,
      datastores, and datastore schemas used by a server.

  o  YANG library content identifier: A server-generated identifier of
      the contents of the YANG library.

  Tree diagrams in this document use the notation defined in [RFC8340].

Bierman, et al.              Standards Track                    [Page 4]
RFC 8525                      YANG Library                    March 2019

2.  Objectives

  The following information is needed by a client application (for each
  YANG module in the library) to fully utilize the YANG data modeling
  language:

  o  name: The name of the YANG module.

  o  revision: If defined in the YANG module or submodule, the revision
      is derived from the most recent revision statement within the
      module or submodule.

  o  submodule list: The name and (if defined) revision of each
      submodule used by the module must be identified.

  o  feature list: The name of each YANG feature supported by the
      server must be identified.

  o  deviation list: The name of each YANG module with deviation
      statements affecting a given YANG module must be identified.

  In addition, the following information is needed by a client
  application for each datastore supported by a server:

  o  identity: The YANG identity for the datastore.

  o  schema: The schema (i.e., the set of modules) implemented by the
      datastore.

  In order to select one out of several possible designs for the YANG
  library data model, the following criteria were used:

  1.  The information must be efficient for a client to consume.  Since
      the size of the YANG library can be quite large, it should be
      possible for clients to cache the YANG library information.

  2.  A dynamic configuration datastore must be able to implement a
      module or feature that is not implemented in the conventional
      configuration datastores.

  3.  It must be possible to not implement a module or feature in
      <operational>, even if it is implemented in some other datastore.
      This is required for transition purposes; a server that wants to
      implement <operational> should not have to implement all modules
      at once.

Bierman, et al.              Standards Track                    [Page 5]
RFC 8525                      YANG Library                    March 2019

  4.  A given module can only be implemented in one revision in all
      datastores.  If a module is implemented in more than one
      datastore, the same revision is implemented in all these
      datastores.

  5.  Multiple revisions can be used for import, if import-by revision
      is used.

  6.  It must be possible to use the YANG library by schema mount
      [RFC8528].

3.  YANG Library Data Model

  The "ietf-yang-library" YANG module provides information about the
  modules, submodules, datastores, and datastore schemas supported by a
  server.  All data nodes in the "ietf-yang-library" module are "config
  false" and thus only accessible in the operational state datastore.

  +-----------+
  | datastore |
  +-----------+
        |
        | has a
        V
  +-----------+            +--------+                +------------+
  | datastore |  union of  | module |  consists of  | modules +  |
  |  schema  |----------->|  set  |--------------->| submodules |
  +-----------+            +--------+                +------------+

                                Figure 1

  The conceptual model of the YANG library is depicted in Figure 1.
  Following the NMDA, every datastore has an associated datastore
  schema.  A datastore schema is a union of module sets, and every
  module set is a collection of modules and submodules, including the
  modules and submodules used for imports.  Note that multiple
  datastores may refer to the same datastore schema.  Furthermore, it
  is possible for individual datastore schemas to share module sets.  A
  common use case is the operational state datastore schema, which is a
  superset of the schema used by conventional configuration datastores.

  Below is the YANG tree diagram for the "ietf-yang-library" module,
  excluding the deprecated "/modules-state" tree:

Bierman, et al.              Standards Track                    [Page 6]
RFC 8525                      YANG Library                    March 2019

  module: ietf-yang-library
    +--ro yang-library
        +--ro module-set* [name]
        |  +--ro name                  string
        |  +--ro module* [name]
        |  |  +--ro name        yang:yang-identifier
        |  |  +--ro revision?    revision-identifier
        |  |  +--ro namespace    inet:uri
        |  |  +--ro location*    inet:uri
        |  |  +--ro submodule* [name]
        |  |  |  +--ro name        yang:yang-identifier
        |  |  |  +--ro revision?  revision-identifier
        |  |  |  +--ro location*  inet:uri
        |  |  +--ro feature*    yang:yang-identifier
        |  |  +--ro deviation*  -> ../../module/name
        |  +--ro import-only-module* [name revision]
        |    +--ro name        yang:yang-identifier
        |    +--ro revision    union
        |    +--ro namespace    inet:uri
        |    +--ro location*    inet:uri
        |    +--ro submodule* [name]
        |        +--ro name        yang:yang-identifier
        |        +--ro revision?  revision-identifier
        |        +--ro location*  inet:uri
        +--ro schema* [name]
        |  +--ro name          string
        |  +--ro module-set*  -> ../../module-set/name
        +--ro datastore* [name]
        |  +--ro name      ds:datastore-ref
        |  +--ro schema    -> ../../schema/name
        +--ro content-id    string

    notifications:
      +---n yang-library-update
          +--ro content-id    -> /yang-library/content-id

  The "/yang-library" container holds the entire YANG library.  The
  container has the following child nodes:

  o  The "/yang-library/module-set" contains entries representing
      module sets.  The list "/yang-library/module-set/module"
      enumerates the modules that belong to the module set.  A module is
      listed together with its submodules (if any), a set of features,
      and any deviation modules.  The list "/yang-library/module-set/
      import-only-module" lists all modules (and their submodules) used
      only for imports.  The assignment of a module to a module set is

Bierman, et al.              Standards Track                    [Page 7]
RFC 8525                      YANG Library                    March 2019

      at the server's discretion.  This revision of the YANG library
      attaches no semantics as to which module set a module is listed
      in.

  o  The "/yang-library/schema" list contains an entry for each
      datastore schema supported by the server.  All conventional
      configuration datastores use the same "schema" list entry.  A
      dynamic configuration datastore may use a different datastore
      schema from the conventional configuration datastores and hence
      may require a separate "schema" entry.  A "schema" entry has a
      leaf-list of references to entries in the "module-set" list.  The
      schema consists of the union of all modules in all referenced
      module sets.

  o  The "/yang-library/datastore" list contains one entry for each
      datastore supported by the server, and it identifies the datastore
      schema associated with a datastore via a reference to an entry in
      the "schema" list.  Each supported conventional configuration
      datastore has a separate entry, pointing to the same "schema" list
      element.

  o  The "/yang-library/content-id" leaf contains the YANG library
      content identifier, which is an implementation-specific identifier
      representing the current information in the YANG library on a
      specific server.  The value of this leaf MUST change whenever the
      information in the YANG library changes.  There is no requirement
      that the same information always result in the same "content-id"
      value.  This leaf allows a client to fetch all schema information
      once, cache it, and only refetch it if the value of this leaf has
      been changed.  If the value of this leaf changes, the server also
      generates a "yang-library-update" notification.

  Note that for a NETCONF server implementing the NETCONF extensions to
  support the NMDA [RFC8526], a change of the YANG library content
  identifier results in a new value for the :yang-library:1.1
  capability defined in [RFC8526].  Thus, if such a server implements
  NETCONF notifications [RFC5277] and the "netconf-capability-change"
  notification [RFC6470], a "netconf-capability-change" notification is
  generated whenever the YANG library content identifier changes.

4.  YANG Library YANG Module

  The "ietf-yang-library" YANG module imports definitions from the
  "ietf-yang-types" and "ietf-inet-types" modules defined in [RFC6991]
  and from the "ietf-datastores" module defined in [RFC8342].  While
  the YANG module is defined using YANG version 1.1, the YANG library
  supports YANG modules written in any version of YANG.

Bierman, et al.              Standards Track                    [Page 8]
RFC 8525                      YANG Library                    March 2019

  <CODE BEGINS> file "ietf-yang-library@2019-01-04.yang"

  module ietf-yang-library {
    yang-version 1.1;
    namespace "urn:ietf:params:xml:ns:yang:ietf-yang-library";
    prefix yanglib;

    import ietf-yang-types {
      prefix yang;
      reference
        "RFC 6991: Common YANG Data Types";
    }
    import ietf-inet-types {
      prefix inet;
      reference
        "RFC 6991: Common YANG Data Types";
    }
    import ietf-datastores {
      prefix ds;
      reference
        "RFC 8342: Network Management Datastore Architecture
                    (NMDA)";
    }

    organization
      "IETF NETCONF (Network Configuration) Working Group";
    contact
      "WG Web:  <https://datatracker.ietf.org/wg/netconf/>
        WG List:  <mailto:netconf@ietf.org>

        Author:  Andy Bierman
                  <mailto:andy@yumaworks.com>

        Author:  Martin Bjorklund
                  <mailto:mbj@tail-f.com>

        Author:  Juergen Schoenwaelder
                  <mailto:j.schoenwaelder@jacobs-university.de>

        Author:  Kent Watsen
                  <mailto:kent+ietf@watsen.net>

        Author:  Robert Wilton
                  <mailto:rwilton@cisco.com>";
    description
      "This module provides information about the YANG modules,
        datastores, and datastore schemas used by a network
        management server.

Bierman, et al.              Standards Track                    [Page 9]
RFC 8525                      YANG Library                    March 2019

        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 (RFC 2119) (RFC 8174) when, and only when,
        they appear in all capitals, as shown here.

        Copyright (c) 2019 IETF Trust and the persons identified as
        authors of the code.  All rights reserved.

        Redistribution and use in source and binary forms, with or
        without modification, is permitted pursuant to, and subject
        to the license terms contained in, the Simplified BSD License
        set forth in Section 4.c of the IETF Trust's Legal Provisions
        Relating to IETF Documents
        (https://trustee.ietf.org/license-info).

        This version of this YANG module is part of RFC 8525; see
        the RFC itself for full legal notices.";

    revision 2019-01-04 {
      description
        "Added support for multiple datastores according to the
          Network Management Datastore Architecture (NMDA).";
      reference
        "RFC 8525: YANG Library";
    }
    revision 2016-04-09 {
      description
        "Initial revision.";
      reference
        "RFC 7895: YANG Module Library";
    }

    /*
      * Typedefs
      */

    typedef revision-identifier {
      type string {
        pattern '\d{4}-\d{2}-\d{2}';
      }
      description
        "Represents a specific date in YYYY-MM-DD format.";
    }

    /*
      * Groupings
      */

Bierman, et al.              Standards Track                  [Page 10]
RFC 8525                      YANG Library                    March 2019

    grouping module-identification-leafs {
      description
       
2013-04-23 Cindy Morgan Chairs changed to Jamal Hadi Salim from Patrick Droz, Jamal Hadi Salim
2012-12-06 (System) Changed milestone "Submit formal definition of controlled objects in functional model", resolved as "Done"
2008-07-23 (System) Changed milestone "Submit protocol selection/definition document to IESG", resolved as "Done"
2008-07-23 (System) Changed milestone "Submit forwarding element functional model document to IESG", resolved as "Done"
2004-04-30 (System) Changed milestone "Submit framework document to IESG", resolved as "Done"
2003-11-30 (System) Changed milestone "Submit requirements document to IESG", resolved as "Done"
2001-07-27 (System) Started group
2001-05-11 (System) Proposed group