ietf-vn

This YANG module for the Virtual Network (VN). It describes a VN operation module that can take place in the context of the Cust...

  • Version: 2025-03-27

    ietf-vn@2025-03-27


    
      module ietf-vn {
    
        yang-version 1.1;
    
        namespace
          "urn:ietf:params:xml:ns:yang:ietf-vn";
    
        prefix vn;
    
        import ietf-yang-types {
          prefix yang;
          reference
            "RFC 6991: Common YANG Data Types";
    
    
        }
        import ietf-network {
          prefix nw;
          reference
            "RFC 8345: A YANG Data Model for Network Topologies";
    
    
        }
        import ietf-network-topology {
          prefix nt;
          reference
            "RFC 8345: A YANG Data Model for Network Topologies";
    
    
        }
        import ietf-te-types {
          prefix te-types;
          reference
            "RFC 8776: Common YANG Data Types for Traffic Engineering";
    
    
        }
        import ietf-te-topology {
          prefix tet;
          reference
            "RFC 8795: YANG Data Model for Traffic Engineering (TE)
            	  Topologies";
    
    
        }
    
        organization
          "IETF Traffic Engineering Architecture and Signaling (TEAS)
         Working Group";
    
        contact
          "WG Web:  <https://datatracker.ietf.org/wg/teas/>
         WG List:  <mailto:teas@ietf.org>
    
         Editor:  Young Lee <younglee.tx@gmail.com>
         Editor:  Dhruv Dhody <dhruv.ietf@gmail.com>";
    
        description
          "This YANG module for the Virtual Network (VN).
         It describes a VN operation module that can take place
         in the context of the Customer Network Controller (CNC) -
         Multi-Domain Service Coordinator (MDSC) interface (CMI) of
         the Abstraction and Control of TE Networks (ACTN)
         architecture where the CNC is the actor of a VN
         instantiation/modification/deletion as per RFC 8453.
    
         Copyright (c) 2025 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 Revised 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 9731; see the
         RFC itself for full legal notices.";
    
        revision "2025-03-27" {
          description "The initial version.";
          reference
            "RFC 9731: A YANG Data Model for Virtual Network (VN)
            	  Operations";
    
        }
    
    
        feature multi-src-dest {
          description
            "Support for selection of one source or destination
           among multiple.";
          reference
            "RFC 8453: Framework for Abstraction and Control of TE
            	  Networks (ACTN)";
    
        }
    
        typedef vn-id {
          type string {
            length "1..max";
          }
          description
            "A type definition for a VN identifier.";
        }
    
        typedef ap-id {
          type string {
            length "1..max";
          }
          description
            "A type definition for an Access Point (AP) identifier.";
        }
    
        typedef vnm-id {
          type string {
            length "1..max";
          }
          description
            "A type definition for a VN-member identifier.";
        }
    
        typedef vn-compute-status {
          type te-types:te-common-status;
          description
            "A type definition for representing the VN compute status.
           Note that all statuses apart from up and down are considered
           to be unknown.";
        }
    
        identity vn-computation-error-reason {
          description
            "Base identity for VN computation error reasons.";
        }
    
        identity vn-computation-error-not-ready {
          base vn-computation-error-reason;
          description
            "VN computation has failed because the MDSC is not
           ready.";
        }
    
        identity vn-computation-error-no-cnc {
          base vn-computation-error-reason;
          description
            "VN computation has failed because one or more dependent
           CNCs are unavailable.";
        }
    
        identity vn-computation-error-no-resource {
          base vn-computation-error-reason;
          description
            "VN computation has failed because there is no
           available resource in one or more domains.";
        }
    
        identity vn-computation-error-path-not-found {
          base vn-computation-error-reason;
          description
            "VN computation failed as no path found.";
        }
    
        identity vn-computation-ap-unknown {
          base vn-computation-error-reason;
          description
            "VN computation failed as the source or destination Access
           Point (AP) not known.";
        }
    
        grouping vn-member {
          description
            "The vn-member is described by this grouping.";
          reference
            "RFC 8454: Information Model for Abstraction and Control of TE
            	  Networks (ACTN)
             RFC 8795: YANG Data Model for Traffic Engineering (TE)
            	  Topologies";
    
          leaf id {
            type vnm-id;
            description
              "A vn-member identifier.";
          }
    
          container src {
            description
              "The source of VN member.";
            leaf ap {
              type leafref {
                path "/access-point/ap/id";
              }
              description
                "A reference to the source AP.";
            }
    
            leaf vn-ap-id {
              type leafref {
                path
                  "/access-point/ap[id=current()/../ap]/vn-ap"
                    + "/id";
              }
              description
                "A reference to the source VNAP.";
            }
    
            leaf multi-src {
              if-feature multi-src-dest;
              type boolean;
              default "false";
              description
                "Is the source part of a multi-source, where
               only one of the sources is enabled?";
            }
          }  // container src
    
          container dest {
            description
              "The destination of the VN member.";
            leaf ap {
              type leafref {
                path "/access-point/ap/id";
              }
              description
                "A reference to the destination AP.";
            }
    
            leaf vn-ap-id {
              type leafref {
                path
                  "/access-point/ap[id=current()/../ap]/"
                    + "vn-ap/id";
              }
              description
                "A reference to the destination VNAP.";
            }
    
            leaf multi-dest {
              if-feature multi-src-dest;
              type boolean;
              default "false";
              description
                "Is the destination part of a multi-destination,
               where only one of the destinations is enabled.";
            }
          }  // container dest
    
          leaf connectivity-matrix-id {
            type leafref {
              path
                "/nw:networks/nw:network/nw:node/tet:te/"
                  + "tet:te-node-attributes/"
                  + "tet:connectivity-matrices/"
                  + "tet:connectivity-matrix/tet:id";
            }
            description
              "A reference to the connectivity-matrix.";
            reference
              "RFC 8795: YANG Data Model for Traffic Engineering (TE)
              	  Topologies";
    
          }
    
          container underlay {
            description
              "An empty container that can be augmented with underlay
             technology information not supported by RFC 8795 (for
             example, Segment Routing (SR).";
          }  // container underlay
        }  // grouping vn-member
    
        grouping vn-policy {
          description
            "policy for VN-level diversity";
          leaf vn-level-diversity {
            type te-types:te-path-disjointness;
            description
              "The type of disjointness on the VN level (i.e., across all
             VN members).";
          }
        }  // grouping vn-policy
    
        container access-point {
          description "AP configurations.";
          reference
            "RFC 8453: Framework for Abstraction and Control of TE
            	  Networks (ACTN), Section 6";
    
          list ap {
            key "id";
            description
              "The access-point identifier.";
            leaf id {
              type ap-id;
              description
                "An AP identifier unique within the scope of the entity
               that controls the VN.";
            }
    
            leaf pe {
              type leafref {
                path "/nw:networks/nw:network/nw:node/tet:te-node-id";
              }
              description
                "A reference to the PE node in the native TE Topology.";
            }
    
            leaf max-bandwidth {
              type te-types:te-bandwidth;
              description
                "The max bandwidth of the AP.";
            }
    
            leaf avl-bandwidth {
              type te-types:te-bandwidth;
              description
                "The available bandwidth of the AP.";
            }
    
            list vn-ap {
              key "id";
              description
                "List of VNAPs in this AP.";
              leaf id {
                type ap-id;
                description
                  "A unique identifier for the VNAP.";
              }
    
              leaf vn {
                type leafref {
                  path "/virtual-network/vn/id";
                }
                description
                  "A reference to the VN.";
              }
    
              leaf abstract-node {
                type leafref {
                  path "/nw:networks/nw:network/nw:node/nw:node-id";
                }
                must
                  '/nw:networks/nw:network/nw:node[nw:node-id='
                    + 'current()/../abstract-node]/tet:te-node-id' {
                  description
                    "The associated network for the abstract-node
                   must be TE enabled.";
                }
                description
                  "A reference to the abstract node that represents
                 the VN.";
              }
    
              leaf ltp {
                type leafref {
                  path "/nw:networks/nw:network/nw:node[nw:node-id=current()/../abstract-node]/nt:termination-point/tet:te-tp-id";
                }
                description
                  "A reference to the Link Termination Point (LTP)
                 in the abstract-node, i.e., the LTP should be in
                 the abstract layer and not the underlying layer.";
                reference
                  "RFC 8795: YANG Data Model for Traffic Engineering (TE)
                  	  Topologies";
    
              }
    
              leaf max-bandwidth {
                type te-types:te-bandwidth;
                config false;
                description
                  "The max bandwidth of the VNAP.";
              }
            }  // list vn-ap
          }  // list ap
        }  // container access-point
    
        container virtual-network {
          description "VN configurations.";
          reference
            "RFC 8453: Framework for Abstraction and Control of TE
            Networks (ACTN)";
    
          list vn {
            key "id";
            description
              "A VN is identified by a vn-id.";
            leaf id {
              type vn-id;
              description
                "An identifier unique within the scope of the entity
               that controls the VN.";
            }
    
            uses te-types:te-topology-identifier;
    
            leaf abstract-node {
              type leafref {
                path "/nw:networks/nw:network/nw:node/tet:te-node-id";
              }
              description
                "A reference to the abstract node in TE Topology.";
            }
    
            list vn-member {
              key "id";
              description
                "List of vn-members in a VN.";
              uses vn-member;
    
              leaf oper-status {
                type te-types:te-oper-status;
                config false;
                description
                  "The vn-member operational state.";
              }
    
              leaf if-selected {
                if-feature multi-src-dest;
                type boolean;
                default "false";
                config false;
                description
                  "Is the vn-member selected among the multi-source
                 or multi-destination options?";
              }
            }  // list vn-member
    
            leaf admin-status {
              type te-types:te-admin-status;
              default "up";
              description
                "VN administrative state.";
            }
    
            leaf oper-status {
              type te-types:te-oper-status;
              config false;
              description
                "VN operational state.";
            }
    
            uses vn-policy;
          }  // list vn
        }  // container virtual-network
    
        rpc vn-compute {
          description
            "The VN computation without actual instantiation.  This is
           used by the CNC to get the VN results without actually
           creating it in the network.
    
           The input could include a reference to the single node
           abstract topology.  It could optionally also include
           constraints and optimization criteria.  The computation
           is done based on the list of VN members.
    
           The output includes a reference to the single node
           abstract topology with each VN member including a
           reference to the connectivity-matrix-id where the
           path properties could be found.  Error information is
           also included.";
          input {
            uses te-types:te-topology-identifier;
    
            leaf abstract-node {
              type leafref {
                path "/nw:networks/nw:network/nw:node/tet:te-node-id";
              }
              description
                "A reference to the abstract node in TE Topology.";
            }
    
            uses te-types:generic-path-constraints;
    
            leaf cos {
              type te-types:te-ds-class;
              description
                "The class of service (COS).";
            }
    
            uses te-types:generic-path-optimization;
    
            list vn-member-list {
              key "id";
              description
                "List of VN members in a VN.";
              uses vn-member;
    
              uses te-types:generic-path-constraints;
    
              leaf cos {
                type te-types:te-ds-class;
                description
                  "The class of service.";
                reference
                  "RFC 4124: Protocol Extensions for Support of
                  Diffserv-aware MPLS Traffic Engineering,
                  Section 4.3.1";
    
              }
    
              uses te-types:generic-path-optimization;
            }  // list vn-member-list
    
            uses vn-policy;
          }
    
          output {
            uses te-types:te-topology-identifier;
    
            leaf abstract-node {
              type leafref {
                path "/nw:networks/nw:network/nw:node/tet:te-node-id";
              }
              description
                "A reference to the abstract node in TE Topology.";
            }
    
            list vn-member-list {
              key "id";
              description
                "List of VN members in a VN.";
              uses vn-member;
    
              leaf if-selected {
                if-feature multi-src-dest;
                type boolean;
                default "false";
                description
                  "Is the vn-member selected among the multi-source or
                 multi-destination options?";
                reference
                  "RFC 8453: Framework for Abstraction and Control of TE
                  	  Networks (ACTN), Section 7";
    
              }
    
              leaf compute-status {
                type vn-compute-status;
                description
                  "The VN-member compute state.";
              }
    
              container error-info {
                description
                  "Error information related to the VN member.";
                leaf error-description {
                  type string {
                    length "1..max";
                  }
                  description
                    "Textual representation of the error that occurred
                   during VN compute.";
                }
    
                leaf error-timestamp {
                  type yang:date-and-time;
                  description
                    "Timestamp of the attempt.";
                }
    
                leaf error-reason {
                  type identityref {
                    base vn-computation-error-reason;
                  }
                  description
                    "Reason for the VN computation error.";
                }
              }  // container error-info
            }  // list vn-member-list
          }
        }  // rpc vn-compute
      }  // module ietf-vn
    

© 2024 YumaWorks, Inc. All rights reserved.