CCAMP Working Group                                   G. Fioccola (Ed.)
                                                         Telecom Italia
Internet Draft                                                   K. Lee
Intended Status: Standard Track                           Korea Telecom
Expires: October 25, December 20, 2018                                 Y. Lee (Ed.)
                                                               D. Dhody
                                                                 Huawei
                                                    O. Gonzalez de-Dios
                                                             Telefonica
                                                          D. Ceccarelli
                                                               Ericsson

                                                         April 25,

                                                          June 20, 2018

        A Yang Data Model for L1 Connectivity Service Model (L1CSM)

                      draft-ietf-ccamp-l1csm-yang-01

                      draft-ietf-ccamp-l1csm-yang-02

Abstract

   This document provides a YANG data model for Layer 1 Connectivity
   Service Model (L1CSM).

Status of this Memo

   This Internet-Draft is submitted to IETF in full conformance with
   the provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as Internet-
   Drafts.

   Internet-Drafts are draft documents valid for a maximum of six
   months and may be updated, replaced, or obsoleted by other documents
   at any time.  It is inappropriate to use Internet-Drafts as
   reference material or to cite them other than as "work in progress."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/ietf/1id-abstracts.txt

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html

   This Internet-Draft will expire on October 25, 2018.

Copyright Notice
   Copyright (c) 2018 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
   (http://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...................................................2
      1.1. Deployment Scenarios......................................3
      1.2. Terminology...............................................6
      1.3. Tree diagram..............................................6
   2. Definitions....................................................7
   3. L1SM YANG Model (Tree Structure)...............................7
   4. L1SM YANG Models....................................................8
      4.1. YANG model for ietf-l1-service-types......................8
      4.2. YANG model for ietf-l1csm................................16 Code.................................................8
   5. Security Considerations.......................................20 Considerations.......................................21
   6. IANA Considerations...........................................21
   7. Acknowledgments...............................................22
   8. References....................................................22 References....................................................23
      8.1. Normative References.....................................22 References.....................................23
      8.2. Informative References...................................22 References...................................23
   9. Contributors..................................................22 Contributors..................................................23
   Authors' Addresses...............................................22 Addresses...............................................23

1. Introduction

   This document provides a YANG data model for L1VPN Connectivity
   Service Model (L1CSM). The intent of this document is to provide a
   transport service model exploiting Yang data model, which can be
   utilized by a client network controller to initiate a service
   request connectivity request as well as retrieving service states
   toward a transport network controller communicating with the client
   controller via a Netconf/Restconf interface.

   [RFC4847] provides a framework and service level requirements for
   Layer 1 Virtual Private Networks (L1VPNs). It classifies service
   models as management-based service model, signaling-based service
   model (Basic Mode) and signaling and routing service model (Enhanced
   Mode).

   In the management-based service model, customer management systems
   and provider management systems communicate with each other.
   Customer management systems access provider management systems to
   request layer 1 connection setup/deletion between a pair of CEs.
   Customer management systems may obtain additional information, such
   as resource availability information and monitoring information,
   from provider management systems.  There is no control message
   exchange between a CE and PE.

   In the signaling-based service model (Basic Model), the CE-PE
   interface's functional repertoire is limited to path setup signaling
   only. In the Signaling and routing service model (Enhanced Mode),
   the CE-PE interface provides the signaling capabilities as in the
   Basic Mode, plus permits limited exchange of information between the
   control planes of the provider and the customer to help such
   functions as discovery of customer network routing information
   (i.e., reachability or TE information in remote customer sites), or
   parameters of the part of the provider's network dedicated to the
   customer.

   The primary focus of this document is to describe L1CS YANG model
   required for the instantiation of point-to-point L1VPN service. A
   L1VPN is a service offered by a core layer 1 network to provide
   layer 1 connectivity between two or more customer sites where the
   customer has some control over the establishment and type of the
   connectivity.

   The model presented in Section 3 is in consistent with [MEF-L1CS].

1.1. Deployment Scenarios

   Figure 1 depicts a deployment scenario of the L1VPN SDN control-
   based service model for an external customer instantiating L1 point-
   to-point connectivity to the provider.

                             +------------+
                             |  Customer  |
                             |   Service  |
                             |Orchestrator|
                             +------------+
                                   |
                     .. .. .. .. .. |.. ..|.. .. .. .. .. ...
                   :             |              :
                     :     +--------------------+     :
                     :     |                    |     :
                     :     |    +----------+    |     :
                     :     |    | Network  |    |     :
                     :     |    |   SDN    |    |     :
                     :     |    |Controller|    |     :
                     :     |    |/NMS/EMS  |    |     :
                     :     |    +----------+    |     :
                     :     |                    |     :
                     :     |                    |     :
           +----+    :   +----+    +----+    +----+   :   +----+
           | CE |----:---| PE |----| P  |----| PE |---:---| CE |
           +----+    :   +----+    +----+    +----+   :   +----+
                     :     |                    |     :
                     :     |                    |     :
                     :     +--------------------+     :
                     :     |                    |     :
                     :     |<-Provider network->|     :

                 Customer                          Customer
                 Interface                         Interface

   Figure 1: L1VPN SDN Controller/EMS/NMS-Based Service Model: External Customer

   With this scenario, the customer service orchestrator interfaces
   with the network SDN controller of the provider using Customer
   Service Model as defined in [Service-Yang].

   Figure 2 depicts another deployment scenario for internal customer
   (e.g., higher-layer service management department(s)) interfacing
   the layer 1 transport network department. With this scenario, a
   multi-service backbone is characterized such that each service
   department of a provider (e.g., L2/3 services) that receives the
   same provider's L1VPN service provides a different kind of higher-
   layer service.  The customer receiving the L1VPN service (i.e., each
   service department) can offer its own services, whose payloads can
   be any layer (e.g., ATM, IP, TDM). The layer 1 transport network and
   each service network belong to the same organization, but may be
   managed separately. The Service SDN Controller is the
   control/management entity owned by higher-layer service department
   (e.g., L2/3 VPN) whereas the Network SDN Controller is the
   control/management entity responsible for Layer 1 connectivity
   service. The CE's in Figure 2 are L2/3 devices that interface with
   L1 PE devices.

                             +----------+
                             | Service  |
                             |   SDN    |
                             |Controller|
                             |/EMS/NMS  |
                             | for L2/3 |
                             +----------+
                                   |
                                   |
                                   |
                           +--------------------+
                           |                    |
                           |    +----------+    |
                           |    | Network  |    |
                           |    |   SDN    |    |
                           |    |Controller|    |
                           |    |/EMS/NMS  |    |
                           |    | for L1VPN|    |
                           |    +----------+    |
                           |                    |
                           |                    |
           +----+        +----+    +----+    +----+      +----+
           | CE |--------| PE |----| P  |----| PE |------| CE |
           +----+        +----+    +----+    +----+      +----+
              |            |                    |          |
              |            |                    |          |
              |            +--------------------+          |
              |            |                    |          |
              |            |<------------------>|          |
              |               Provider Network             |
              |                  For Layer 1               |
             |<------------------------------------------>|
                          Provider Network for L2/3

   Figure 2: L1VPN SDN Controller/EMS/NMS-Based Service Model: Internal Customer
   The benefit is that the same layer 1 transport network resources are
   shared by multiple services.  A large capacity backbone network
   (data plane) can be built economically by having the resources
   shared by multiple services usually with flexibility to modify
   topologies, while separating the control functions for each service
   department. Thus, each customer can select a specific set of
   features that are needed to provide their own service [RFC4847].

1.2. Terminology

   Refer to [RFC4847] and [RFC5253] for the key terms used in this
   document.

   The following terms are defined in [RFC6241] and are not redefined
   here:

   o client

   o configuration data

   o server

   o state data

   The following terms are defined in [RFC6020] and are not redefined
   here:

   o augment

   o data model

   o data node

   The terminology for describing YANG data models is found in
   [RFC6020].

1.3. Tree diagram

   A simplified graphical representation of the data model is presented
   in Section x.

   The meaning of the symbols in these diagrams is as follows:

   o Brackets "[" and "]" enclose list keys.

   o Curly braces "{" and "}" contain names of optional features that
   make the corresponding node conditional.

   o Abbreviations before data node names: "rw" means configuration
   (read-write), and "ro" state data (read-only).

   o Symbols after data node names: "?" means an optional node and "*"
   denotes a "list" or "leaf-list".

   o Parentheses enclose choice and case nodes, and case nodes are also
   marked with a colon (":").

   o Ellipsis ("...") stands for contents of subtrees that are not
   shown.

2. Definitions

   TDB

3. L1SM YANG Model (Tree Structure)

module: ietf-l1csm
    +--rw l1cs
       +--rw access
       |  +--rw uni-list* [UNI-ID]
       |     +--rw UNI-ID               string
       |     +--rw protocol?            identityref
       |     +--rw coding?              identityref
       |     +--rw optical_interface?   identityref
       +--rw service
          +--rw service-list* [subscriber-l1vc-id]
             +--rw subscriber-l1vc-id    string
             +--rw service-config
                +--rw subscriber-l1vc-id?         string
                +--rw subscriber-l1vc-ep-ingress? subscriber-l1vc-ep-id-1?    string
                +--rw subscriber-l1vc-ep-id-2?    string
                +--rw subscriber-l1vc-ep-UNI-1?   -> /l1cs/access/uni-list/UNI-
   ID /l1cs/access/uni-
list/UNI-ID
                +--rw subscriber-l1vc-ep-egress? subscriber-l1vc-ep-UNI-2?   -> /l1cs/access/uni-list/UNI-
   ID /l1cs/access/uni-
list/UNI-ID
                +--rw time-start?                 yang:date-and-time
                +--rw time-interval?              int64
                +--rw performance-metric?           Identityref         identityref

4. L1SM YANG Models

   We have two YANG models described in this section.

   The first model is ietf-l1-service-types that describes generic
   physical layer service attributes and performance-metric. (See
   Section 4.1)

   The second model is ietf-l1csm that describes L1 Connectivity
   Service. (See Section 4.2)

4.1. YANG model for ietf-l1-service-types Code

   The YANG code is as follows:

   <CODE BEGINS> file "ietf-l1-service-types@2018-04-11.yang" "ietf-l1csm@2018-06-20.yang"

module ietf-l1-service-types ietf-l1csm {
        yang-version 1.1;
        namespace "urn:ietf:params:xml:ns:yang:ietf-l1-service-types"; "urn:ietf:params:xml:ns:yang:ietf-l1csm";

        prefix "l1csm";

        import ietf-yang-types {
            prefix "yang";
        }

        import ietf-l1-mef-service-types {
            prefix "l1-st";
        }

        organization
         "IETF
          "Internet Engineering Task Force (IETF) CCAMP Working Group"; WG";

        contact
         "WG Web: <http://tools.ietf.org/wg/ccamp/>
         WG List: <mailto:ccamp@ietf.org>

         Editor:

          "Editor: G. Fioccolla(giuseppe.fioccola@telecomitalia.it) Fioccolla (giuseppe.fioccola@telecomitalia.it)
          Editor: K. Lee (kwangkoog.lee@kt.com)
          Editor: Y. Lee (leeyoung@huawei.com)
          Editor: D. Dhody (dhruv.ietf@gmail.com)
          Editor: O. Gonzalez de-Dios(oscar.gonzalezdedios@telefonica.com) de-Dio(oscar.gonzalezdedios@telefonica.com)
          Editor: D. Ceccarelli(daniele.ceccarelli@ericsson.com)"; Ceccarelli (daniele.ceccarelli@ericsson.com)";

        description
         "This
             "this module defines L1 describes Layer 1 connectivity service types.";
             model for subscriber Layer 1 Connectivity Services
             and Attributes";

        revision "2018-04-11" 2018-06-20 {
                    description
             "Revision 0.1";
                              "updated version to incorporate MEF
comments";
                              reference "TBD"; "to add the draft name";

          }

     identity protocol-type

          revision 2018-04-11 {
                description
          "base identity from which client protocol type is derived.";
                        "Initial revision.";
                        reference "to add the draft name";
        }

          identity aGigE

          grouping protocol-coding-optical_interface {
                    base "protocol-type";
                    description
                              "GigE
                              "describes <p,c,o>";
                         leaf protocol type";
          }

          identity a10GigE_WAN {
                    base "protocol-type";
                    description
                              "10GigE-WAN protocol type";
          }

          identity a10GigE_LAN
                              type identityref {
                                   base "protocol-type"; "l1-st:protocol-type";
                             }

                              description
                              "10GigE-LAN protocol type"; "List of physical layer L1VC
client protocol";
                         }

          identity a40GigE

                         leaf coding {
                              type identityref {
                                   base "protocol-type"; "l1-st:coding-func";
                              }

                              description
                              "40GigE protocol type"; "coding function";
                         }

          identity a100GigE

                         leaf optical_interface {
                              type identityref {
                                   base "protocol-type"; "l1-st:optical-interface-func";
                              }

                              description
                              "100GigE protocol type"; "optical-interface-function";
                         }

          identity FC-100
          }

        grouping uni-attributes {
                    base "protocol-type";
                    description
                              "Fiber Channel - 100 protocol type";
          }

          identity FC-200
                              "uni-service-attributes";

                              leaf UNI-ID {
                    base "protocol-type";
                                        type string;
                                        description
                              "Fiber Channel - 200 protocol type"; "the UNI id of UNI
Service Attributes";
                              }
          identity FC-400

                              uses protocol-coding-optical_interface;

          }

          grouping subscriber-l1vc-sls-service-attribute {
                    base "protocol-type";
                    description
                              "Fiber Channel - 400 protocol type";
          }

          identity FC-800
                              "The value of the Subscriber L1VC SLS
(Service Level Specification) Service Attribute expressed in a 3-tuple of the
form.";

                              leaf time-start {
                    base "protocol-type";
                                        type yang:date-and-time;
                                        description
                              "Fiber Channel - 800 protocol type"; "a time that represent
the date and time for the start of the SLS";
                              }

          identity FC-1200

                              leaf time-interval {
                    base "protocol-type";
                                        type int64;
                                        units seconds;
                                        description
                              "Fiber Channel - 1200 protocol type"; "a time interval
(e.g., 1 month) that is used in conjunction wuth time-start to specify a
contiguous sequence of time intervals T for determining when performance
objectives are met.";
                              }

          identity FC-1600

                              leaf performance-metric {
                                        type identityref {
                                             base "protocol-type"; "l1-st:performance-"
                                                  +"metriclist";
                                        }

                                        description
                              "Fiber Channel - 1600 protocol type"; "list of performance
metric";
                              }

          identity FC-3200
          }

          grouping subscriber-l1vc-service-attributes {
                    base "protocol-type";
                    description
                              "Fiber Channel - 3200 protocol type";
          }

          identity STM-1
                              "subscriber layer 1 connection service
service level";
                    leaf subscriber-l1vc-id {
                    base "protocol-type";
                              type string;
                              description
                              "SDH STM-1 protocol type"; "subscriber L1VC identifier";
                    }

          identity STM-4

                    leaf subscriber-l1vc-ep-id-1 {
                    base "protocol-type";
                              type string;
                              description
                              "SDH STM-4 protocol type"; "subscriber end point ID";
                    }

          identity STM-16

                    leaf subscriber-l1vc-ep-id-2 {
                    base "protocol-type";
                              type string;
                              description
                              "SDH STM-16 protocol type"; "subscriber end point ID";
                    }

          identity STM-64

                    leaf subscriber-l1vc-ep-UNI-1 {
                    base "protocol-type";
                         type leafref {
                         path "/l1cs/access/uni-list/UNI-ID";
                         }
                         description
                              "SDH STM-64 protocol type"; "this is one end of subscriber L1VC end
point ID value = UNI-1";
                    }

          identity STM-256

                    leaf subscriber-l1vc-ep-UNI-2 {
                    base "protocol-type";
                         type leafref {
                         path "/l1cs/access/uni-list/UNI-ID";
                         }
                         description
                              "SDH STM-256 protocol type"; "this is the other end of subscriber
L1VC end point ID value = UNI-2";
                    }

          identity OC-3

                    uses subscriber-l1vc-sls-service-attribute;
          }

          grouping subscriber-attributes {
                    base "protocol-type";
                    description
                              "SONET OC-3 protocol type";
                              "subscriber attributes";

                    uses subscriber-l1vc-service-attributes;

          }

          identity OC-12

        container l1cs {
                    base "protocol-type";
                description
                              "SONET OC-12
                        "serves as a top-level container for a list of layer 1
connection services (l1cs)";

                    container access {
                        description "UNI configurations";

                         list uni-list {
                              key "UNI-ID";
                              description "uni identifier";
                              uses uni-attributes {
                                   description "UNI attributes
information";
                              }
                         }

                    }

                    container service {
                         description "L1VC service";
                         list service-list {
                        key "subscriber-l1vc-id";
                        description
                                "an unique identifier of a service";

                        leaf subscriber-l1vc-id {
                                type string;
                                description "a unique service identifier for
L1VC.";
                        }
                        container service-config {
                                description "service-config container";

                              uses subscriber-attributes;

                        }//end of service-config
                         }//end of service list
                    } //end of service container

        }//service top container
}

   <CODE ENDS>

   <CODE BEGINS> file "ietf-l1-mef-service-types@2018-06-20.yang"

module ietf-l1-mef-service-types {
     namespace "urn:ietf:params:xml:ns:yang:ietf-l1-mef-service-types";
     prefix "l1-st";

     organization
         "IETF CCAMP Working Group";
     contact
         "WG Web: <http://tools.ietf.org/wg/ccamp/>
         WG List: <mailto:ccamp@ietf.org>

         Editor: G. Fioccolla(giuseppe.fioccola@telecomitalia.it)
         Editor: K. Lee (kwangkoog.lee@kt.com)
         Editor: Y. Lee (leeyoung@huawei.com)
         Editor: D. Dhody (dhruv.ietf@gmail.com)
         Editor: O. Gonzalez de-Dios(oscar.gonzalezdedios@telefonica.com)
         Editor: D. Ceccarelli(daniele.ceccarelli@ericsson.com)";

     description
         "This module defines L1 service types based on MEF subscriber Layer 1
Connectivity Service Attribute.";

     revision "2019-06-20" {
         description
             "Revision 0.2";
         reference "TBD";
     }

     revision "2018-04-11" {
         description
             "Revision 0.1";
         reference "TBD";
     }

     identity protocol-type {
          description
          "base identity from which client protocol type"; type is derived.";
          }

          identity OC-48 aGigE {
                    base "protocol-type";
                    description
                              "SONET OC-48
                              "GigE protocol type";
          }

          identity OC-192 a10GigE_WAN {
                    base "protocol-type";
                    description
                              "SONET OC-192
                              "10GigE-WAN protocol type";
          }

          identity OC-768 a10GigE_LAN {
                    base "protocol-type";
                    description
                              "SONET OC-768
                              "10GigE-LAN protocol type";
          }

          identity coding-func a40GigE {
                    base "protocol-type";
                    description
          "base identity from which coding func is derived.";
                              "40GigE protocol type";
          }

          identity a1000X-PCS-36 a100GigE {
                    base "coding-func"; "protocol-type";
                    description
                              "PCS clause 36 coding function that
corresponds to 1000BASE-X";
                              "100GigE protocol type";
          }

          identity a10GW-PCS-49-WIS-50 FC-100 {
                    base "coding-func"; "protocol-type";
                    description
                              "PCS clause 49 and WIS clause 50 coding func
that corresponds to 10GBASE-W (WAN PHY)";
                              "Fiber Channel - 100 protocol type";
          }

          identity a10GR-PCS-49 FC-200 {
                    base "protocol-type";
                    description
                              "Fiber Channel - 200 protocol type";
          }

          identity FC-400 {
                    base "protocol-type";
                    description
                              "Fiber Channel - 400 protocol type";
          }

          identity FC-800 {
                    base "protocol-type";
                    description
                              "Fiber Channel - 800 protocol type";
          }

          identity FC-1200 {
                    base "protocol-type";
                    description
                              "Fiber Channel - 1200 protocol type";
          }

          identity FC-1600 {
                    base "protocol-type";
                    description
                              "Fiber Channel - 1600 protocol type";
          }

          identity FC-3200 {
                    base "protocol-type";
                    description
                              "Fiber Channel - 3200 protocol type";
          }

          identity STM-1 {
                    base "protocol-type";
                    description
                              "SDH STM-1 protocol type";
          }

          identity STM-4 {
                    base "protocol-type";
                    description
                              "SDH STM-4 protocol type";
          }

          identity STM-16 {
                    base "protocol-type";
                    description
                              "SDH STM-16 protocol type";

          }

          identity STM-64 {
                    base "protocol-type";
                    description
                              "SDH STM-64 protocol type";
          }

          identity STM-256 {
                    base "protocol-type";
                    description
                              "SDH STM-256 protocol type";
          }

          identity OC-3 {
                    base "protocol-type";
                    description
                              "SONET OC-3 protocol type";
          }

          identity OC-12 {
                    base "protocol-type";
                    description
                              "SONET OC-12 protocol type";
          }

          identity OC-48 {
                    base "protocol-type";
                    description
                              "SONET OC-48 protocol type";
          }

          identity OC-192 {
                    base "protocol-type";
                    description
                              "SONET OC-192 protocol type";
          }

          identity OC-768 {
                    base "protocol-type";
                    description
                              "SONET OC-768 protocol type";
          }

     identity coding-func {
          description
          "base identity from which coding func is derived.";
     }

          identity a1000X-PCS-36 {
                    base "coding-func";
                    description
                              "PCS clause 36 coding function that
corresponds to 1000BASE-X";
          }

          identity a10GW-PCS-49-WIS-50 {
                    base "coding-func";
                    description
                              "PCS clause 49 and WIS clause 50 coding func
that corresponds to 10GBASE-W (WAN PHY)";
          }

          identity a10GR-PCS-49 {
                    base "coding-func";
                    description
                              "PCS clause 49 coding function that
corresponds to 10GBASE-R (LAN PHY)";
          }

          identity a40GR-PCS-82 {
                    base "coding-func";
                    description
                              "PCS clause 82 coding function that
corresponds to 40GBASE-R";
          }

          identity a100GR-PCS-82 {
                    base "coding-func";
                    description
                              "PCS clause 82 coding function that
corresponds to 100GBASE-R";
          }

          /* coding func needs to expand for Fiber Channel, SONET, SDH  */

     identity optical-interface-func {
          description
          "base identity from which optical-interface-function is derived.";

     }

          identity SX-PMD-clause-38 {
                    base "optical-interface-func";
                    description
                              "SX-PMD-clause-38 Optical Interface function
for 1000BASE-X PCS-36";
          }

          identity LX-PMD-clause-38 {
                    base "optical-interface-func";
                    description
                              "LX-PMD-clause-38 Optical Interface function
for 1000BASE-X PCS-36";
          }

          identity LX10-PMD-clause-59 {
                    base "optical-interface-func";
                    description
                              "LX10-PMD-clause-59 Optical Interface
function for 1000BASE-X PCS-36";
          }

          identity BX10-PMD-clause-59 {
                    base "optical-interface-func";
                    description
                              "BX10-PMD-clause-59 Optical Interface
function for 1000BASE-X PCS-36";
          }

          identity LW-PMD-clause-52 {
                    base "optical-interface-func";
                    description
                              "LW-PMD-clause-52 Optical Interface function
for 10GBASE-W PCS-49-WIS-50";
          }

          identity EW-PMD-clause-52 {
                    base "optical-interface-func";
                    description
                              "EW-PMD-clause-52 Optical Interface function
for 10GBASE-W PCS-49-WIS-50";
          }

          identity LR-PMD-clause-52 {
                    base "optical-interface-func";
                    description
                              "LR-PMD-clause-52 Optical Interface function
for 10GBASE-R PCS-49";
          }

          identity ER-PMD-clause-52 {
                    base "optical-interface-func";
                    description
                              "ER-PMD-clause-52 Optical Interface function
for 10GBASE-R PCS-49";
          }

          identity LR4-PMD-clause-87 {
                    base "optical-interface-func";
                    description
                              "LR4-PMD-clause-87 Optical Interface function
for 40GBASE-R PCS-82";
          }

          identity ER4-PMD-clause-87 {
                    base "optical-interface-func";
                    description
                              "ER4-PMD-clause-87 Optical Interface function
for 40GBASE-R PCS-82";
          }

          identity FR-PMD-clause-89 {
                    base "optical-interface-func";
                    description
                              "FR-PMD-clause-89 Optical Interface function
for 40GBASE-R PCS-82";
          }

          identity LR4-PMD-clause-88 {
                    base "optical-interface-func";
                    description
                              "LR4-PMD-clause-88 Optical Interface function
for 100GBASE-R PCS-82";
          }

          identity ER4-PMD-clause-88 {
                    base "optical-interface-func";
                    description
                              "ER4-PMD-clause-88 Optical Interface function
for 100GBASE-R PCS-82";
          }

          /* optical interface func needs to expand for Fiber Channel, SONET
and SDH */

     identity performance-metriclist {
          description "list of performance metric";
     }

          identity One-way-Delay {
                    base "performance-metriclist";
                    description "one-way-delay";
          }

          identity One-way-Errored-Second {
                    base "performance-metriclist";
                    description "one-way-errored-second";
          }

          identity One-way-Severely-Errored-Second {
                    base "performance-metriclist";
                    description "one-way-severely-errored-second";
          }

          identity One-way-Unavailable-Second {
                    base "performance-metriclist";
                    description "one-way-unavailable-second";
          }

          identity One-way-Availability {
                    base "performance-metriclist";
                    description "one-way-availability";
          }

 }

   <CODE BEGINS>

4.2. YANG model for ietf-l1csm

   The YANG code is as follows:

   <CODE BEGINS> file "ietf-l1csm@2018-04-11.yang"

module ietf-l1csm {
        yang-version 1.1;
        namespace "urn:ietf:params:xml:ns:yang:ietf-l1csm";

        prefix "l1csm";

        import ietf-yang-types {
            prefix "yang";
        }

        import ietf-l1-service-types {
            prefix "l1-st";
        }

        organization
          "Internet Engineering Task Force (IETF) CCAMP WG";

        contact

          "Editor: G. Fioccolla (giuseppe.fioccola@telecomitalia.it)
          Editor: K. Lee (kwangkoog.lee@kt.com)
          Editor: Y. Lee (leeyoung@huawei.com)
          Editor: D. Dhody (dhruv.ietf@gmail.com)
          Editor: O. Gonzalez de-Dio(oscar.gonzalezdedios@telefonica.com)
          Editor: D. Ceccarelli (daniele.ceccarelli@ericsson.com)";

        description
             "this module describes Layer 1 connectivity service
             model for subscriber Layer 1 Connectivity Services
             and Attributes";

        revision 2018-04-11 {
                description
                        "Initial revision.";
                        reference "to add the draft name";

        }

          grouping protocol-coding-optical_interface {
                    description
                              "describes <p,c,o>";
                         leaf protocol {
                              type identityref {
                                   base "l1-st:protocol-type";
                             }

                              description "List of physical layer L1VC
client protocol";
                         }

                         leaf coding {
                              type identityref {
                                   base "l1-st:coding-func";
                              }

                              description "coding function";
                         }

                         leaf optical_interface {
                              type identityref {
                                   base "l1-st:optical-interface-func";
                              }

                              description "optical-interface-function";
                         }
          }

        grouping uni-attributes {
                    description
                              "uni-service-attributes";

                              leaf UNI-ID {
                                        type string;
                                        description "the UNI id of UNI
Service Attributes";
                              }

                              uses protocol-coding-optical_interface;

          }
          grouping subscriber-l1vc-sls-service-attribute {
                    description
                              "The value of the Subscriber L1VC SLS
(Service Level Specification) Service Attribute expressed in a 3-tuple of the
form.";

                              leaf time-start {
                                        type yang:date-and-time;
                                        description "a time that represent
the date and time for the start of the SLS";
                              }

                              leaf time-interval {
                                        type int64;
                                        units seconds;
                                        description "a time interval
(e.g., 1 month) that is used in conjunction wuth time-start to specify a
contiguous sequence of time intervals T for determining when performance
objectives are met.";
                              }

                              leaf performance-metric {
                                        type identityref {
                                             base "l1-st:performance-"
+"metriclist";
                                        }

                                        description "list of performance
metric";
                              }
          }

          grouping subscriber-l1vc-service-attributes {
                    description
                              "subscriber layer 1 connection service
service level";

                    leaf subscriber-l1vc-id {
                              type string;
                    base "optical-interface-func";
                    description "subscriber L1VC identifier";
                              "LR-PMD-clause-52 Optical Interface function
for 10GBASE-R PCS-49";
          }

                    leaf subscriber-l1vc-ep-ingress {
                         type leafref

          identity ER-PMD-clause-52 {
                         path "/l1cs/access/uni-list/UNI-ID";
                         }
                    base "optical-interface-func";
                    description "this is one end of subscriber L1VC end
point ID value = UNI-1";
                              "ER-PMD-clause-52 Optical Interface function
for 10GBASE-R PCS-49";
          }

                    leaf subscriber-l1vc-ep-egress {
                         type leafref

          identity LR4-PMD-clause-87 {
                         path "/l1cs/access/uni-list/UNI-ID";
                         }
                    base "optical-interface-func";
                    description "this is the other end of subscriber
L1VC end point ID value = UNI-2";
                    }

                    uses subscriber-l1vc-sls-service-attribute;
                              "LR4-PMD-clause-87 Optical Interface function
for 40GBASE-R PCS-82";
          }

          grouping subscriber-attributes

          identity ER4-PMD-clause-87 {
                    base "optical-interface-func";
                    description
                              "subscriber attributes";

                    uses subscriber-l1vc-service-attributes;
                              "ER4-PMD-clause-87 Optical Interface function
for 40GBASE-R PCS-82";
          }

        container l1cs

          identity FR-PMD-clause-89 {
                    base "optical-interface-func";
                    description
                        "serves as a top-level container
                              "FR-PMD-clause-89 Optical Interface function
for a list of layer 1
connection services (l1cs)";

                    container access 40GBASE-R PCS-82";
          }

          identity LR4-PMD-clause-88 {
                    base "optical-interface-func";
                    description "UNI configurations";

                         list uni-list
                              "LR4-PMD-clause-88 Optical Interface function
for 100GBASE-R PCS-82";
          }

          identity ER4-PMD-clause-88 {
                              key "UNI-ID";
                    base "optical-interface-func";
                    description "uni identifier";
                              uses uni-attributes
                              "ER4-PMD-clause-88 Optical Interface function
for 100GBASE-R PCS-82";
          }

          /* optical interface func needs to expand for Fiber Channel, SONET
and SDH */

     identity performance-metriclist {
          description "UNI attributes
information";
                              } "list of performance metric";
     }

          identity One-way-Delay {
                    base "performance-metriclist";
                    description "one-way-delay";
          }

                    container service

          identity One-way-Errored-Second {
                    base "performance-metriclist";
                    description "L1VC service";
                         list service-list "one-way-errored-second";
          }

          identity One-way-Severely-Errored-Second {
                        key "subscriber-l1vc-id";
                    base "performance-metriclist";
                    description
                                "an unique identifier of a service";

                        leaf subscriber-l1vc-id "one-way-severely-errored-second";
          }

          identity One-way-Unavailable-Second {
                                type string;
                    base "performance-metriclist";
                    description "a unique service identifier for
L1VC."; "one-way-unavailable-second";
          }
                        container service-config

          identity One-way-Availability {
                    base "performance-metriclist";
                    description "service-config container";

                              uses subscriber-attributes;

                        }//end of service-config
                         }//end of service list "one-way-availability";
          } //end of service container

        }//service top container

 }

   <CODE ENDS>

5. Security Considerations

   The configuration, state, and action data defined in this document
   are designed to be accessed via a management protocol with a secure
   transport layer, such as NETCONF [RFC6241].  The NETCONF access
   control model [RFC6536] provides the means to restrict access for
   particular NETCONF users to a preconfigured subset of all available
   NETCONF protocol operations and content.

   A number of configuration data nodes defined in this document are
   writable/deletable (i.e., "config true") These data nodes may be
   considered sensitive or vulnerable in some network environments.

6. IANA Considerations

   This document registers the following namespace URIs in the IETF XML
   registry [RFC3688]:

   --------------------------------------------------------------------
   URI: urn:ietf:params:xml:ns:yang:ietf-l1csm
   Registrant Contact: The IESG.
   XML: N/A, the requested URI is an XML namespace.
   --------------------------------------------------------------------

   --------------------------------------------------------------------
   URI: urn:ietf:params:xml:ns:yang:ietf-l1-service-types urn:ietf:params:xml:ns:yang:ietf-l1-mef-service-types
   Registrant Contact: The IESG.
   XML: N/A, the requested URI is an XML namespace.
   --------------------------------------------------------------------

   This document registers the following YANG modules in the YANG
   Module

   Names registry [RFC7950]:

   --------------------------------------------------------------------
   name:         ietf-l1csm
   namespace:    urn:ietf:params:xml:ns:yang:ietf-l1csm
   reference:    RFC XXXX (TDB)
   --------------------------------------------------------------------
   --------------------------------------------------------------------
   name:         ietf-l1-service-types         ietf-l1-mef-service-types
   namespace:    urn:ietf:params:xml:ns:yang:ietf-l1-service-types    urn:ietf:params:xml:ns:yang:ietf-l1-mef-service-types
   reference:    RFC XXXX (TDB)
   --------------------------------------------------------------------

7. Acknowledgments

   The authors would like to thank Italo Busi for his helpful comments
   and valuable contributions.

8. References

   8.1. Normative References

   [MEF-L1CS] "Subscriber Layer 1 Connectivity Service Attributes",
             Working Draft (WD) v0.09 December 13, 2017.

   8.2. Informative References

   [RFC4847] T. Takeda (Editor), "Framework and Requirements for Layer
             1 Virtual Private Networks", RFC 4847, April 2007.

   [RFC5253] T. Takeda, "Applicability Statement for Layer 1 Virtual
             Private Network (L1VPN) Basic Mode", RFC 5253, July 2008.

   [Service-Yang] Q. Wu, et al, "Service Models Explained", draft-wu-
             opsawg-service-model-explained, Work in progress.

9. Contributors

Contributor's Addresses

   I. Busi
   Huawei
   Email: Italo.Busi@huawei.com

Authors' Addresses

   G. Fioccola (Editor)
   Telecom Italia
   Email: giuseppe.fioccola@telecomitalia.it

   K. Lee
   KT
   Email: kwangkoog.lee@kt.com

   Y. Lee (Editor)
   Huawei
   Email: leeyoung@huawei.com

   D. Dhody
   Huawei
   Email: dhruv.ietf@gmail.com

   O. Gonzalez de Dios
   Telefonica
   Email: oscar.gonzalezdedios@telefonica.com

   D. Ceccarelli
   Ericsson
   Email: daniele.ceccarelli@ericsson.com