<?xml version="1.0" encoding="US-ASCII"?>
<!-- This template is for creating an Internet Draft using xml2rfc,               
    which is available here: http://xml.resource.org. -->
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY rfc2119 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY rfc3688 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.3688.xml">
<!ENTITY rfc6020 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.6020.xml">
<!ENTITY rfc7950 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.6020.xml">
<!ENTITY rfc8174 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.8174.xml">
<!ENTITY rfc8340 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.8340.xml">
<!ENTITY rfc8342 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.8342.xml">
]>
<rfc category="std" docName="draft-zhang-vni-yang-model-00"
     ipr="trust200902">
  <?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>

  <!-- used by XSLT processors -->

  <!-- For a complete list and description of processing instructions (PIs),        
    please see http://xml.resource.org/authoring/README.html. -->

  <!-- Below are generally applicable Processing Instructions (PIs) that
    most I-Ds might want to use.
    (Here they are set differently than their defaults in xml2rfc
    v1.32) -->

  <?rfc strict="yes" ?>

  <!-- give errors regarding ID-nits and DTD validation -->

  <!-- control the table of contents (ToC) -->

  <?rfc toc="yes"?>

  <!-- generate a ToC -->

  <?rfc tocdepth="4"?>

  <?rfc compact="yes" ?>

  <front>
    <title abbrev="vnic YANG model">YANG Data Model for Virtual Network Interfaces Management</title>

    <author fullname="Fan Zhang" initials="F" role="editor" surname="Zhang">
      <organization>China Telecom</organization>

      <address>
        <email>zhangf52@chinatelecom.cn</email>
      </address>
    </author>

    <date year="2025"/>

    <area>ops</area>

    <workgroup>NeoTec</workgroup>

    <abstract>
      <t>This document defines a YANG data model for the management of VNIs (Virtual Network Interfaces), 
        including vNIC and CNI, depending on the different ways of virtualization. It exposes 
        the real-time VNI resources to network controller and service orchestrator in order to supervise 
        the cloud resource states for dynamic adjustment of service function placement and load-balancing of service instances
        to ensure the SLO (Service Level Objective). </t>
    </abstract>
  </front>

  <middle>
    <section anchor="intro" title="Introduction">
      <t>Telecom operators rely on edge cloud infrastructure to deliver services 
        to end users for low-latency. However, edge cloud resources are relatively limited.
        It is necessary to monitor resource consumption in real time to optimize service deployment 
        and load balancing strategies. While telecom operators have control over both cloud and network domains, 
        there are still gaps in achieving effective cloud-network coordination.</t>

      <t>This document defines a YANG data model for the management of VNIs (Virtual Network Interfaces), 
        including vNIC and CNI, depending on the different ways of virtualization. It exposes 
        the real-time VNI resources to network controller and service orchestrator in order to supervise 
        the cloud resource states for dynamic adjustment of service function placement and load-balancing of service instances
        to ensure the SLO (Service Level Objective). </t>

      <t>The YANG modules in this document conform to the Network Management
      Datastore Architecture (NMDA) <xref target="RFC8342"/>.</t>

      <section title="Terminology">
        <t>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] <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only
        when, they appear in all capitals, as shown here.</t>

        <t>The terminology for describing YANG data models is found in <xref
        target="RFC7950"/>.</t>

        <t>The following conventions are used in this document.</t>

        <t><list style="symbols">
            <t>VNI: Virtual Network Interfaces, including vNIC and CNI.</t>

            <t>vNIC: virtual Network Interface Card, based on VM (Virtual Machine).</t>

            <t>CNI: Container Network Interface, based on container, like Kubernetes.</t>
          </list></t>
      </section>

      <section title="Tree Diagrams">
        <t>Tree diagrams used in this document follow the notation defined in
        <xref target="RFC8340"/>.</t>
      </section>
    </section>

    <section anchor="design" title="Design of the Data Model">
      <t>This data model intends to expose the information of VNIs to the 
        network controller and service orchestrator for a better coordination 
        between cloud and network systems. Specifically, it collects the type of 
        virtualization, the latency, bandwidth, utilization, priority, and 
        packet loss rate of VNI of virtualized nodes in clouds. Generally, there are two mainstream approaches to virtualization 
        in cloud environments, which are VM based on Openstacks 
        and container based on Kubernetes. </t>
      
      <t>
        Based on the information of VNIs, the operators can not only optimize the service deployment
        and load-balancing strategies in edge clouds, but also dynamically adjust
        the route and flow between DCs and end users in order to ensure the SLO. 
      </t>

      </section>

      <section title="YANG Tree of VNI Management YANG Data Model">
        <t>This document defines the YANG module "ietf-vni-mng", which has the
        following structure:</t>

        <figure>
          <artwork><![CDATA[
module: ietf-vni-mng
  +--rw dc
     +--rw dc-id?   string
     +--rw nodes
        +--rw node* [node-id]
           +--rw node-id                  string
           +--rw node-type?               enumeration
           +--rw allocatable-bandwidth?   uint64
           +--rw allocated-bandwidth?     uint64
           +--rw bandwidth-usage?         uint64
           +--rw priority?                uint8
           +--rw latency?                 uint64
           +--rw packet-loss-rate?        uint64
           +--rw ingress-bytes?           uint64
           +--rw egress-bytes?            uint64
           +--rw policy* [policy-id]
              +--rw policy-id     string
              +--rw service-id?   string
        ]]></artwork>
        </figure>
      </section>

    <section anchor="yangmodel" title="VNI Management YANG Module">
      <t>This section presents the VNI Management YANG module defined in this
      document.</t>


      <figure>
        <artwork><![CDATA[<CODE BEGINS> file "ietf-vni-mng@2025-07-07.yang"
module ietf-vni-mng {
  yang-version 1.1;
  namespace "urn:ietf:params:xml:ns:yang:ietf-vni-mng";
  prefix vni-mng;

  organization
    "XXX";
  contact
    "WG Web: <http://tools.ietf.org/wg/neotec/>
     WG List: <mailto: neotec@ietf.org>

     Author:  Fan Zhang
              <zhangf52@chinatelecom.cn>";
  description
    "This document defines a YANG data model for the management
     of VNIs (Virtual Network Interfaces), including vNIC and CNI,
     depending on the different ways of virtualization. It exposes
     the real-time VNI resources to network controller and service
     orchestrator in order to supervise the cloud resource states
     for dynamic adjustment of service function placement and
     load-balancing of service instances to ensure the
     SLO (Service Level Objective).

     The model is based on YANG 1.1 as defined in RFC 7950 and
     conforms to Network Management Datastore Architecture (NMDA)
     as defined in RFC 8342.

     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 Simplified BSD License
     set forth in Section 4.c of the IETF Trust's Legal Provisions
     Relating to IETF Documents
     (http://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 2025-07-07 {
    description
      "Init revision";
    reference
      "YANG Data Model for Virtual Network Interfaces Management";
  }

  /* Data nodes */

  container dc {
    description
      "Datacenter";
    leaf dc-id {
      type string;
      description
        "Identifier for the datacenter";
    }
    container nodes {
      description
        "Virtualized nodes (VMs or containers)";
      list node {
        key "node-id";
        description
          "List of virtualized nodes.";
        leaf node-id {
          type string;
          description
            "Identifier for the virtualized node.";
        }
        leaf node-type {
          type enumeration {
            enum vm {
              description
                "Indicates that the node is a Virtual
                 Machine (VM) instance.";
            }
            enum container {
              description
                "Indicates that the node is a Container instance.";
            }
          }
          description
            "Specifies the type of the node.";
        }
        leaf allocatable-bandwidth {
          type uint64;
          units "bps";
          description
            "The maximum allocatable bandwidth for the
             node's virtualized interface.";
        }
        leaf allocated-bandwidth {
          type uint64;
          units "bps";
          description
            "The allocated bandwidth for the node's
             virtualized interface.";
        }
        leaf bandwidth-usage {
          type uint64;
          units "bps";
          description
            "The current bandwidth usage on the node's
             virtualized interface.";
        }
        leaf priority {
          type uint8;
          description
            "Priority level of the node or its traffic,
             with lower values indicating higher priority.";
        }
        leaf latency {
          type uint64;
          units "ms";
          description
            "Average one-way latency experienced by the
             node.";
        }
        leaf packet-loss-rate {
          type uint64;
          units "%";
          description
            "The average packet loss rate observed on the
             node's virtualized interface.";
        }
        leaf ingress-bytes {
          type uint64;
          units "bytes";
          description
            "Total number of bytes received by the node.";
        }
        leaf egress-bytes {
          type uint64;
          units "bytes";
          description
            "Total number of bytes transmitted from the
             node.";
        }
        list policy {
          key "policy-id";
          description
            "The service deployed on the node and its
             related policy.";
          leaf policy-id {
            type string;
            description
              "Identifier for the policy of the service
               deployed on the node.";
          }
          leaf service-id {
            type string;
            description
              "Identifier for the service deployed on the
               node.";
          }
        }
      }
    }
  }
}
<CODE ENDS>
]]></artwork>
      </figure>
    </section>


    <section title="IANA Considerations">
      <t>This document registers a URI in the <xref target="RFC3688">IETF XML
      registry</xref>. Following the format in <xref target="RFC3688"/>, the
      following registration is requested to be made:</t>

      <figure>
        <artwork><![CDATA[
    URI: urn:ietf:params:xml:ns:yang:ietf-vni-mng
    Registrant Contact: The XXX WG of the IETF.
    XML: N/A, the requested URI is an XML namespace.
        ]]></artwork>
      </figure>

      <t>This document registers a YANG module in the YANG Module Names
      registry <xref target="RFC6020"/>.</t>

      <figure>
        <artwork><![CDATA[
    Name: ietf-vni-mng
    Namespace: urn:ietf:params:xml:ns:yang:ietf-vni-mng
    Prefix: vni-mng
    Reference: RFC XXXX
        ]]></artwork>
      </figure>
    </section>

    <section anchor="security" title="Security Considerations">
      <t>TBD.</t>

    </section>

    <section anchor="ack" title="Acknowledgments">
      <t>The authors wish to thank xxx for their helpful comments.</t>
    </section>

    <!---->
  </middle>

  <back>
    <references title="Normative References">
      <?rfc include='reference.RFC.2119'?>
      <?rfc include='reference.RFC.3688'?>
      <?rfc include='reference.RFC.6020'?>
      <?rfc include='reference.RFC.7950'?>      
      <?rfc include='reference.RFC.8174'?>
      <?rfc include='reference.RFC.8342'?>
    </references>

    <references title="Informative References">
      <?rfc include='reference.RFC.8340'?>
    </references>

  </back>
</rfc>
