<?xml version="1.0" encoding="US-ASCII"?> 
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<!--  vi: set et smarttab sw=2 tabstop=4:--> 
<?rfc toc="yes"?> 
<?rfc tocompact="yes"?> 
<?rfc tocdepth="3"?> 
<?rfc tocindent="yes"?> 
<?rfc symrefs="yes"?> 
<?rfc sortrefs="yes"?> 
<?rfc comments="yes"?> 
<?rfc inline="yes"?> 
<?rfc compact="yes"?> 
<?rfc subcompact="no"?> 

<rfc category="std" docName="draft-zheng-ccamp-client-pm-yang-00" ipr="trust200902" obsoletes="" updates="" submissionType="IETF" xml:lang="en">
 <front>
  <title abbrev="PM YANG for Client Signal"> A YANG Data Model for Client Signal Performance Monitoring  </title> 

  <author initials="H." surname="Zheng" fullname="Haomian Zheng">
   <organization>Huawei Technologies</organization>
   <address>
    <postal>
     <street>H1-1-A043S Huawei Industrial Base, Songshanhu</street>
     <city>Dongguan</city>
     <region>Guangdong</region>
     <code>523808</code>
     <country>China</country>
    </postal>
    <email>zhenghaomian@huawei.com</email>
   </address>
  </author>
  
    <author initials="I." surname="Busi" fullname="Italo Busi">
   <organization>Huawei Technologies</organization>
   <address>
    <postal>
     <street></street>
     <city></city>
     <region></region>
     <code></code>
     <country></country>
    </postal>
    <email>Italo.Busi@huawei.com</email>
   </address>
  </author>
  
      <author initials="Y." surname="Zheng" fullname="Yanlei Zheng">
   <organization>China Unicom</organization>
   <address>
    <postal>
     <street></street>
     <city></city>
     <region></region>
     <code></code>
     <country></country>
    </postal>
    <email>zhengyanlei@chinaunicom.cn</email>
   </address>
  </author>

  <date  month="November" day="4" year="2019" />
  <workgroup>CCAMP Working Group</workgroup>

 <abstract>
  <t>
  A transport network is a server-layer network to provide connectivity services to its client. Given the client signal is configured, the followup function for performance monitoring, such as latency and bit error rate, would be needed for network operation. 
  </t>
  <t>
  This document describes the data model to support the performance monitoring functionalities. The module carefully maps to relevant performance monitoring standards.
  </t>
 </abstract>

 <!--
 <note title="Requirements Language">
  <t>
  The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in 
  <xref target="RFC2119" pageno="false" format="default" />. 
  </t>
 </note>
 -->
 </front>


 <middle>
 <section title="Introduction" toc="default">
  <t>
  Client-layer network and server-layer network have been respectively modeled to allow the tunnels carrying the client traffic. Server-layers are modeled as tunnels with various switching technologies, such as <xref target="I-D.ietf-ccamp-otn-tunnel-model" /> and <xref target="I-D.ietf-ccamp-wson-tunnel-model" />. Client-layers are modeled as client signals according to the client-signal identities specified in  <xref target="I-D.ietf-ccamp-layer1-types" />.  
  </t>
  <t>
  In the network operation, the operator is interested in monitoring for their instantiated client signal over tunnels. The objective for such monitoring is to complete timely adjustment once there is abnormal statistic which may result in failure of the client signal. The parameters specified in the performance monitoring model can be collected for the operation need.
  </t>
 </section> 
 <!--  Introduction END  -->

 <section title="Terminology and Notations" toc="default">
  <t>
  A simplified graphical representation of the data model is used in this document. The meaning of the symbols in the YANG data tree presented later in this document is defined in <xref target="RFC8340" />. They are provided below for reference.
  </t>
  <t>
  <list style="symbols">
   <t>
   Brackets "[" and "]" enclose list keys.
   </t>
   <t>
   Abbreviations before data node names: "rw" means configuration (read-write) and "ro" state data (read-only).
   </t>
   <t>
   Symbols after data node names: "?" means an optional node, "!"  means a presence container, and "*" denotes a list and leaf-list.
   </t>
   <t>
   Parentheses enclose choice and case nodes, and case nodes are also marked with a colon (":").
   </t>
   <t>
   Ellipsis ("...") stands for contents of subtrees that are not shown.
   </t>
  </list>
  </t>
 </section>
 <!--  Terminology and Notation END  -->

  <section title="Model Relationship" toc="default">
  <t>
  <xref target="I-D.ietf-ccamp-client-signal-yang" /> has specified the two models for the client signal configuration, module ietf-trans-client-service for transparent client service and module ietf-eth-tran-service for Ethernet service. A common types module, ietf-eth-tran-types, has also been defined for the common use for service configuration. Basically the client signal types in this document is consistent with ietf-eth-tran-types, and focus on different functionality. On the perspective of operator, the modules in <xref target="I-D.ietf-ccamp-client-signal-yang" /> can be used to configure the service given any underlay tunnels, while the operation about monitoring the performance on given service can be achieved by using the model in this document.
  </t>
  <t>
  Consideration on Key Performance Information (KPI) monitoring for Virtual Network (VN) and tunnels has been specified in <xref target="I-D.ietf-teas-actn-pm-telemetry-autonomics" />. Usually the monitoring on the tunnels are the VNs should be separately deployed for the network operation, but it is possible to have common parameters that are both needed for the VN/TE and the configured services. Common types are imported in both modules. 
  </t>
  <t>
  VPN-level parameters and their monitoring have been defined in <xref target="I-D.www-bess-yang-vpn-service-pm" />. This module focus on the performance on the topology at different layer or the overlay topology between VPN sites. On the other hand, this document is focusing on the performance of the service configured between Customer Ends (CE), as described in <xref target="I-D.ietf-ccamp-client-signal-yang" />. 
  </t>
 </section>
  <!--  Model Relationship END  -->
  
  <section title="Consideration on Monitoring Parameters" toc="default">
  <t>
  There can be multiple groups of parameters for monitoring, such as latency, bit error rate (BER). Some of these parameters are layer-dependent, for example, packet loss is only applicable in packet networks are won't be neede for layer 1 OTN and layer 0 WSON. 
  </t>
  <t>
  This document starts with the specification of the latency measurement for both Ethernet service and client signal service. In the future version additional parameters would be added into the data model in the same approach as the latency in the current version. A candidate list of parameters to be monitored include: Latency, Packet Loss, Bit Error Rate (BER), Jitter, Bandwidth, Byte/Packet number and so on. 
  </t>
 </section>
   <!--  Monitoring Parameters END  -->

 <section anchor="YANGTree" title="YANG Model for Client Signal Performance Monitoring" toc="default">
  <section anchor="ETHTree" title="YANG Tree for Ethernet Performance Monitoring " toc="default">
   <t>
   <figure anchor="ETHtreefigure" title="" suppress-title="true" align="left" alt="" width="" height="">
    <artwork xml:space="preserve" name="" type="" align="left" alt="" width="" height="">
<![CDATA[

module: ietf-eth-service-pm
  +--rw performance-monitoring
     +--rw service-pm* [service-name]
        +--rw service-name          leafref
        +--rw pm-enable?            boolean
        +--rw latency-monitoring
        |  +--rw latency-measure-enable?   boolean
        +--ro service-pm-state
           +--ro start-time?            yang:date-and-time
           +--ro last-update-time?      yang:date-and-time
           +--ro latency?               uint32
           +--ro error-message?         string
           +--ro service-oper-status?   identityref


]]> 
    </artwork>
   </figure>
   </t>
  </section>
  <!--  tree END  --> 

  <section anchor="ClientTree" title="YANG Tree for Transparent Client Signal Performance Monitoring" toc="default">
   <t>
   <figure anchor="Clienttreefigure" title="" suppress-title="true" align="left" alt="" width="" height="">
    <artwork xml:space="preserve" name="" type="" align="left" alt="" width="" height="">
<![CDATA[

module: ietf-trans-client-svc-pm
  +--rw performance-monitoring
     +--rw service-pm* [service-name]
        +--rw service-name          leafref
        +--rw pm-enable?            boolean
        +--rw latency-monitoring
        |  +--rw latency-measure-enable?   boolean
        +--ro service-pm-state
           +--ro start-time?            yang:date-and-time
           +--ro last-update-time?      yang:date-and-time
           +--ro latency?               uint32
           +--ro error-message?         string
           +--ro service-oper-status?   identityref


]]> 
    </artwork>
   </figure>
   </t>
  </section>
  <!--  Othertree END  -->
  
</section>
 <!--  YANG TREE END  -->

 <section title="YANG Code for Performance Monitoring" toc="default">
  <section anchor="ETHcode" title="The ETH Service Performance Monitoring YANG Code" toc="default">
   <figure anchor="ETHYANGCode" title="" suppress-title="true" align="left" alt="" width="" height="">
    <artwork xml:space="preserve" name="" type="" align="left" alt="" width="" height="">
 <![CDATA[ 
<CODE BEGINS> file "ietf-eth-service-pm@2019-11-04.yang"
module ietf-eth-service-pm {
  /* TODO: FIXME */
  yang-version 1.1;

  namespace "urn:ietf:params:xml:ns:yang:ietf-eth-service-pm";
  prefix "ethsvc-pm";

  import ietf-eth-tran-service {
    prefix "ethtsvc";
  }

  import ietf-eth-tran-types {
    prefix "etht-types";
  }

  import ietf-yang-types {
    prefix "yang";
  }

  import ietf-te-types {
    prefix "te-types";
  }

  organization
    "Internet Engineering Task Force (IETF) CCAMP WG";
  contact
    "
      WG List: <mailto:ccamp@ietf.org>

      ID-draft editor:
        Haomian Zheng (zhenghaomian@huawei.com);
        Italo Busi (italo.busi@huawei.com);
        Yanlei Zheng (zhengyanlei@chinaunicom.cn);
    ";

  description
    "This module defines the performance monitoring for Ethernet 
     services. The model fully conforms to the Network Management 
     Datastore Architecture (NMDA).
    
     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 XXXX; see
     the RFC itself for full legal notices.";
  
  revision 2019-11-04 {
    description
      "Initial version";
    reference
      "ADD REFERENCE HERE";
  }

  container performance-monitoring {
    description 
      "This part is for performance monitoring. ";
    list service-pm {
      key "service-name";
      description
        "The list of service to be monitored.";
      leaf service-name {
        type leafref {
          path "/ethtsvc:etht-svc/ethtsvc:etht-svc-instances/ethtsvc:etht-svc-name";
        }
        description "The name of service.";
      }
      
      leaf pm-enable {
        type boolean;
        description
          "Indicate whether the performance monitoring 
          is enable or not.";
      }
      
      container latency-monitoring {
        description 
          "To monitor the latency of service.";
        leaf latency-measure-enable {
          type boolean;
          description
            "Indicate whether the latency measurement 
            is enable or not.";
        }
      }
      
      container service-pm-state {
        config false;
        description 
          "The state of service performance monitoring.";
        leaf start-time {
          type yang:date-and-time;
          description 
            "The time stamp when the service is started.";
        }
        
        leaf last-update-time {
          type yang:date-and-time;
          description 
            "The time stamp when the service is last updated.";
        }
        
        leaf latency {
          type uint32;
          units microsecond;
          description 
            "The latency of service.";
        }
        
        leaf error-message {
          type string;
          description 
            "The message of error.";
        }
        
        leaf service-oper-status {
          type identityref {
            base te-types:tunnel-state-type;
          }
          description 
            "The operational status of the services.";
        }
      }
    }
  }
}

<CODE ENDS>
]]> 
    </artwork>
   </figure>  
  </section>
  <!--  ETH YANG CODE END  -->

 <section anchor="OtherCode" title="The Transparent Client Signals Performance Monitoring YANG Code" toc="default">
   <figure anchor="ClientYANGCode" title="" suppress-title="true" align="left" alt="" width="" height="">
    <artwork xml:space="preserve" name="" type="" align="left" alt="" width="" height="">
 <![CDATA[ 
<CODE BEGINS> file "ietf-trans-client-svc-pm@2019-11-04.yang"
module ietf-trans-client-svc-pm {
  /* TODO: FIXME */
  yang-version 1.1;
  namespace "urn:ietf:params:xml:ns:yang:ietf-trans-client-svc-pm";
  prefix "clntsvc-pm";
  
  import ietf-trans-client-service {
    prefix "clntsvc";
  }
  
  import ietf-yang-types {
    prefix "yang";
  }

  import ietf-te-types {
    prefix "te-types";
  }
  
  organization
    "Internet Engineering Task Force (IETF) CCAMP WG";
  contact
    "
      WG List: <mailto:ccamp@ietf.org>

      ID-draft editor:
        Haomian Zheng (zhenghaomian@huawei.com);
        Italo Busi (italo.busi@huawei.com);
        Yanlei Zheng (zhengyanlei@chinaunicom.cn);
    ";

  description
    "This module defines the performance monitoring for transparent 
     client signals. The model fully conforms to the Network Management 
     Datastore Architecture (NMDA).
    
     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 XXXX; see
     the RFC itself for full legal notices.";
     
  revision 2019-11-04 {
    description
      "Initial version";
    reference
      "ADD REFERENCE HERE";
  }
  
  container performance-monitoring {
    description 
      "This part is for performance monitoring. ";
    list service-pm {
      key "service-name";
      description
        "The list of service to be monitored.";
      leaf service-name {
        type leafref {
          path "/clntsvc:client-svc/clntsvc:client-svc-instances/clntsvc:client-svc-name";
        }
        description "The name of service.";
      }
    
      leaf pm-enable {
        type boolean;
        description
          "Indicate whether the performance monitoring 
          is enable or not.";
      }
    
      container latency-monitoring {
        description 
          "To monitor the latency of service.";
        leaf latency-measure-enable {
          type boolean;
          description
            "Indicate whether the latency measurement 
            is enable or not.";
        }
      
      }
      
      container service-pm-state {
        config false;
        description 
          "The state of service performance monitoring.";

        leaf start-time {
          type yang:date-and-time;
          description 
            "The time stamp when the service is started.";
        }
    
        leaf last-update-time {
          type yang:date-and-time;
          description 
            "The time stamp when the service is last updated.";
          
        }
    
        leaf latency {
          type uint32;
          units microsecond;
          description 
            "The latency of service.";
        }

        leaf error-message {
          type string;
          description 
            "The message of error.";
        }

        leaf service-oper-status {
          type identityref {
            base te-types:tunnel-state-type;
          
          }
          description 
            "The operational status of the services.";
        }
      }
    }
  }
}


<CODE ENDS>
]]> 
    </artwork>
   </figure>  
    </section>
 </section>
 <!--  YANG Code Chapter END  -->


 <section anchor="IANA" title="IANA Considerations" toc="default">
 <t>
  It is proposed that IANA should assign new URIs from the "IETF XML Registry" <xref target="RFC3688" /> as follows:
  </t>
  <figure>
    <artwork>
      <![CDATA[
      URI: urn:ietf:params:xml:ns:yang:ietf-eth-service-pm  
      Registrant Contact: The IESG  
      XML: N/A; the requested URI is an XML namespace.
    ]]>
    </artwork>
    </figure>
      <figure>
    <artwork>
      <![CDATA[
      URI: urn:ietf:params:xml:ns:yang:ietf-trans-client-svc-pm  
      Registrant Contact: The IESG  
      XML: N/A; the requested URI is an XML namespace.
        ]]>
    </artwork>
    </figure>
  <t> 
   This document registers following YANG modules in the YANG Module Names registry <xref target="RFC7950" />.
    </t>
    <figure>
    <artwork>
      <![CDATA[
         name:         ietf-eth-service-pm
         namespace:    urn:ietf:params:xml:ns:yang:ietf-eth-service-pm
         prefix:       ethsvc-pm
         reference:    RFC XXXX (This document)
        ]]>
    </artwork>
    </figure>
    <figure>
    <artwork>
      <![CDATA[
        name:         ietf-trans-client-svc-pm
        namespace:    urn:ietf:params:xml:ns:yang:ietf-trans-client-svc-pm
        prefix:       clntsvc-pm
        reference:    RFC XXXX (This document)
      ]]>
    </artwork>
    </figure>

 </section>
 <!--  IANA END  -->

 <section title="Manageability Considerations" toc="default">
  <t>
  TBD.
  </t>
 </section>
 <!--  Manageability END  -->

 <section anchor="Security" title="Security Considerations" toc="default">
  <t>
  The data following the model defined in this document is exchanged via, for example, the interface between an orchestrator and a transport network controller. The security concerns mentioned in <xref target="I-D.ietf-ccamp-client-signal-yang" /> also applies to this document.
  </t>
  <t>
  The YANG module defined in this document can be accessed via the RESTCONF protocol defined in <xref target="RFC8040" />, or maybe via the NETCONF protocol <xref target="RFC6241" />. 
  </t>

 </section>
 <!--  Security END  -->


 <!--  Acknowledgements END  -->

 <section anchor="Contributor" title="Contributors" toc="default">

  <t>
  Chaode YU
  <vspace blankLines="0" /> 
  Huawei Technologies, 
  <vspace blankLines="0" /> 
  Email: yuchaode@huawei.com
  <vspace blankLines="0" /> 
  </t>

 </section>
 <!--  Contributor END  --> 
 </middle>


 <back>
 <references title="Normative References">
  <!--<?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml"?> --> 
  <?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.3688.xml"?>
  <?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.6241.xml"?> 
  <?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.7950.xml"?>
  <?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.8040.xml"?>  
  <?rfc include="reference.I-D.ietf-ccamp-client-signal-yang"?>
  <?rfc include="reference.I-D.ietf-ccamp-layer1-types"?>
  <?rfc include="reference.I-D.www-bess-yang-vpn-service-pm"?>
  <?rfc include="reference.I-D.ietf-teas-actn-pm-telemetry-autonomics"?>
 </references>
 <!--  Normative END  -->

 <references title="Informative References">
  <?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.8340.xml"?> 
  <?rfc include="reference.I-D.ietf-ccamp-wson-tunnel-model"?>
  <?rfc include="reference.I-D.ietf-ccamp-otn-tunnel-model"?>
  </references>
 <!--  Informative END  -->
 </back>
</rfc>
