BGP NLRI App Meta Data for 5G Edge Computing Service
draft-dunbar-idr-5g-edge-compute-app-meta-data-02

Document Type Active Internet-Draft (individual)
Authors Linda Dunbar  , Kausik Majumdar  , Haibo Wang 
Last updated 2021-03-08
Stream (None)
Intended RFC status (None)
Formats plain text pdf htmlized bibtex
Stream Stream state (No stream defined)
Consensus Boilerplate Unknown
RFC Editor Note (None)
IESG IESG state I-D Exists
Telechat date
Responsible AD (None)
Send notices to (None)
Network Working Group                                   L. Dunbar
Internet Draft                                          Futurewei
Intended status: Standard                             K. Majumdar
Expires: September 8, 2021                              CommScope
                                                          H. Wang
                                                           Huawei
                                                    March 8, 2021

        BGP NLRI App Meta Data for 5G Edge Computing Service
         draft-dunbar-idr-5g-edge-compute-app-meta-data-02

Abstract
   This draft describes a new BGP Network Layer Reachability
   Information (BGP NLRI) Path Attribute, AppMetaData, for egress
   router to advertise the running status and environment of the
   directly attached 5G Edge Computing servers. The AppMetaData
   can be used by the ingress routers in the 5G Local Data
   Network to make intelligent path selection for flows from UEs.
   The goal is to improve latency and performance for 5G Edge
   Computing services.

   The extension enables a feature, called soft anchoring, which
   makes one Edge Computing Server at one specific location to be
   more preferred than others for the same application to receive
   packets from a specific source (UE).

Status of this Memo

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

   This Internet-Draft is submitted in full conformance with the
   provisions of BCP 78 and BCP 79. This document may not be
   modified, and derivative works of it may not be created,
   except to publish it as an RFC and to translate it into
   languages other than English.

   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.

xxx, et al.           Expires September 8, 2021          [Page 1]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   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 April 7, 2021.

Copyright Notice

   Copyright (c) 2021 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.............................................. 3
      1.1. 5G Edge Computing Background......................... 3
      1.2. 5G Edge Computing Network Properties................. 4
      1.3. Problem#1: ANYCAST in 5G EC Environment.............. 6
      1.4. Problem #2: Unbalanced Anycast Distribution due to UE
      Mobility.................................................. 7
      1.5. Problem 3: Application Server Relocation............. 7
   2. Conventions used in this document......................... 8
   3. Usage of App-Meta-Data for 5G Edge Computing.............. 9

Dunbar, et al.        Expires September 8, 2021          [Page 2]
Internet-Draft    AppMetaData NLRI for 5G EC Service

      3.1. Assumptions.......................................... 9
      3.2. IP Layer Metrics to Gauge Application Behavior....... 9
      3.3. To Equalize among Multiple ANYCAST Locations........ 11
      3.4. BGP Protocol Extension to advertise Load & Capacity. 11
      3.5. Ingress Node BGP Path Selection Behavior............ 12
         3.5.1. AppMetaData Influenced BGP Path Selection...... 12
         3.5.2. Forwarding Behavior............................ 12
         3.5.3. Forwarding Behavior after a UE moving to a new 5G
         Site.................................................. 13
   4. The NLRI Path Attribute for App-Meta-Data................ 14
      4.1. Load Measurement sub-TLV format..................... 16
      4.2. Capacity Index sub-TLV format....................... 17
      4.3. The Site Preference Index sub-TLV format............ 17
   5. AppMetaData Propagation Scope............................ 18
   6. Soft Anchoring of an ANYCAST Flow........................ 18
   7. Manageability Considerations............................. 20
   8. Security Considerations.................................. 20
   9. IANA Considerations...................................... 20
   10. References.............................................. 20
      10.1. Normative References............................... 20
      10.2. Informative References............................. 21
   11. Acknowledgments......................................... 22

1. Introduction

   This document describes a new BGP Network Layer Reachability
   Information (BGP NLRI) Path Attribute, AppMetaData, for egress
   routers to advertise the running status and environment of the
   directly attached Edge Computing servers. The AppMetaData can
   be used by the ingress routers in the 5G Local Data Network to
   make intelligent path selection for flows from UEs. The goal
   is to improve latency and performance for 5G Edge Computing
   services.

   1.1. 5G Edge Computing Background

   As described in [5G-EC-Metrics], one Application can have
   multiple Application Servers hosted in different Edge
   Computing data centers that are close in proximity. Those Edge
   Computing (mini) data centers are usually very close to or co-
   located with the 5G base stations, to minimize latency and
   optimize the user experience.

   When a UE (User Equipment) initiates application packets using
   the destination address from a DNS reply or its cache, the

Dunbar, et al.        Expires September 8, 2021          [Page 3]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   packets from the UE are carried in a PDU session through 5G
   Core [5GC] to the 5G UPF-PSA (User Plan Function - PDU Session
   Anchor). The UPF-PSA decapsulates the 5G GTP outer header and
   forwards the packets from the UEs to the Ingress router of the
   Edge Computing (EC) Local Data Network (LDN). The LDN for 5G
   EC, which is the IP Networks from the 5GC perspective, is
   responsible for forwarding the packets to the intended
   destinations.

   When the UE moves out of coverage of its current gNB (next-
   generation Node B) (gNB1), handover procedures are initiated
   and the 5G SMF (Session Management Function) also selects a
   new UPF-PSA. The standard handover procedures described in
   3GPP TS 23.501 and TS 23.502 are followed. When the handover
   process is complete, the UE has a new IP address and the IP
   point of attachment is to the new UPF-PSA. 5GC may maintain a
   path from the old UPF to new the UPF for a short time for the
   SSC [Session and Service Continuity] mode 3 to make the
   handover process more seamless.

  1.2. 5G Edge Computing Network Properties

   In this document, 5G Edge Computing Network refers to multiple
   Local IP Data Networks (LDN) in one region that interconnect
   the Edge Computing mini-data centers. Those IP LDN networks
   are the N6 interfaces from 3GPP 5G perspective.

   The ingress routers to the 5G Edge Computing Network are the
   routers directly connected to 5G UPFs. The egress routers to
   the 5G Edge Computing Network are the routers that have a
   direct link to the Edge Computing servers. The servers and the
   egress routers are co-located. Some of those mini Edge
   Computing Data centers may have Virtual switches or Top of
   Rack switches between the egress routers and the servers. But
   transmission delay between the egress routers and the Edge
   Computing servers is too small to be considered in this
   document.

   When one mini data center has multiple Edge Computing Servers
   attached to one App Layer Load Balancer, only the App Layer
   Load Balancer is visible to the 5G Edge Computing Network. How

Dunbar, et al.        Expires September 8, 2021          [Page 4]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   the App Layer Load balancer manages the individual servers is
   out of the scope of the network layer.

   The Edge Computer Services are specially managed services that
   need to utilize the network topology and balance among
   multiple mini Edge Computing Data Centers with the same
   ANYCAST address. UEs can access many services that are not
   part of the registered 5G Edge Computing Services.

   +--+
   |UE|---\+---------+                 +------------------+
   +--+    |  5G     |     +--------+  |   S1: aa08::4450 |
   +--+    | Site +--+-+---+        +----+                |
   |UE|----|  A   |PSA1| Ra|        | R1 | S2: aa08::4460 |
   +--+    |      +----+---+        +----+                |
  +---+    |         |  |           |  |   S3: aa08::4470 |
  |UE1|---/+---------+  |           |  +------------------+
  +---+                 |IP Network |       L-DN1
                        |(3GPP N6)  |
     |                  |           |  +------------------+
     | UE1              |           |  |  S1: aa08::4450  |
     | moves to         |          +----+                 |
     | Site B           |          | R3 | S2: aa08::4460  |
     v                  |          +----+                 |
                        |           |  |  S3: aa08::4470  |
                        |           |  +------------------+
                        |           |      L-DN3
   +--+                 |           |
   |UE|---\+---------+  |           |  +------------------+
   +--+    |  5G     |  |           |  |  S1: aa08::4450  |
   +--+    | Site +--+--+---+       +----+                |
   |UE|----|  B   |PSA2| Rb |       | R2 | S2: aa08::4460 |
   +--+    |      +--+-+----+       +----+                |
   +--+    |         |  +-----------+  |  S3: aa08::4470  |
   |UE|---/+---------+                 +------------------+
   +--+                                     L-DN2
            Figure 1: App Servers in different edge DCs

Dunbar, et al.        Expires September 8, 2021          [Page 5]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   1.3. Problem#1: ANYCAST in 5G EC Environment

   Increasingly, Anycast is used extensively by various
   application providers and CDNs because ANYCAST makes it
   possible to dynamically load balance across server locations
   based on network conditions.

   Using Anycast address leverages the proximity information
   present in the network (routing) layer and eliminates the
   single point of failure and bottleneck at the DNS resolvers
   and application layer load balancers. Another benefit of using
   the ANYCAST address is removing the dependency on UEs. Some
   UEs (or clients) might use their cached IP addresses instead
   of querying DNS for an extended period.

   But, having multiple locations of the same ANYCAST address in
   the 5G Edge Computing environment can be problematic because
   all those edge computing Data Centers can be close in
   proximity.  There might be a very small difference in the
   routing cost to reach the Application Servers in different
   Edge DCs. This list elaborates the issues in detail:

     a) Path Selection: When a new flow comes to an ingress node
        (Ra), how to select the optimal egress router to reach an
        ANYCAST server.

        The mechanism described in this draft is for solving this
        Path Selection problem.

     b) How Ingress node keeps the packets from one flow to the
        same ANYCAST server.

        a.k.a. Flow Affinity, or Flow-based load balancing, which
        is supported by many commercial routers.

        The ingress node, (Ra/Rb) uses Flow ID (in IPv6 header)
        or UDP/TCP port number combined with the source address
        to enforce packets in one flow being placed in one tunnel
        to one Egress router.  No new features are needed.

     c) When a UE moves to a new Cell Tower, a method is needed
        to stick the flow to the same ANYCAST server, which is
        required by 5G Edge Computing: 3GPP TR 23.748.

Dunbar, et al.        Expires September 8, 2021          [Page 6]
Internet-Draft    AppMetaData NLRI for 5G EC Service

        This problem is Out of scope for this draft.  [5g-edge-
        compute-sticky-service] describes several approaches to
        solve this problem.

   BGP is an integral part of the way IP Anycast usually
   functions. Within BGP routing there are multiple routes for
   the same IP address which are pointing to different locations.

   This draft describes the BGP UPDATE extension to allow the App
   Servers Running status and environment to be included in the
   BGP UPDATE messages, so that ingress routers can optimize its
   path selection algorithm to select an optimal ANYCAST location
   based on the combination of network delay, the App Server load
   index, the location capacity index and the location
   preference.

 1.4. Problem #2: Unbalanced Anycast Distribution due to UE
     Mobility

   UEs frequent moving from one 5G site to another can make it
   difficult to plan where the App ANYCAST servers should be
   hosted. When one App server is heavily utilized, other App
   servers of the same address close-by can be very
   underutilized. Since the condition can be short-lived, it is
   difficult for the application controller to anticipate the
   move and adjust.

  1.5. Problem 3: Application Server Relocation

   When an Application Server is added to, moved, or deleted from
   a 5G Edge Computing Data Center, the routing protocol needs to
   propagate the changes to 5G PSA or the PSA adjacent routers.
   After the change, the cost associated with the site [5G-EC-
   Metrics] might change as well.

   Note: for ease of description, the Edge Application Server and
   Application Server are used interchangeably throughout this
   document.

Dunbar, et al.        Expires September 8, 2021          [Page 7]
Internet-Draft    AppMetaData NLRI for 5G EC Service

2. Conventions used in this document

   A-ER:       Egress Router to an Application Server, [A-ER] is
               used to describe the last router that the
               Application Server is attached. For a 5G EC
               environment, the A-ER can be the gateway router to
               a (mini) Edge Computing Data Center.

   Application Server: An application server is a physical or
               virtual server that hosts the software system for
               the application.

   Application Server Location: Represent a cluster of servers at
               one location serving the same Application. One
               application may have a Layer 7 Load balancer,
               whose address(es) are reachable from an external
               IP network, in front of a set of application
               servers. From an IP network perspective, this
               whole group of servers is considered as the
               Application server at the location.

   Edge Application Server: used interchangeably with Application
               Server throughout this document.

   EC:         Edge Computing

   Edge Hosting Environment: An environment providing the support
               required for Edge Application Server's execution.

               NOTE: The above terminologies are the same as
               those used in 3GPP TR 23.758

   Edge DC:    Edge Data Center, which provides the Edge
               Computing Hosting Environment. An Edge DC might
               host 5G core functions in addition to the
               frequently used application servers.

   gNB         next generation Node B

   L-DN:       Local Data Network

Dunbar, et al.        Expires September 8, 2021          [Page 8]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   PSA:        PDU Session Anchor (UPF)

   SSC:        Session and Service Continuity

   UE:         User Equipment

   UPF:        User Plane Function

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL
   NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT
   RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be
   interpreted as described in BCP 14 [RFC2119] [RFC8174] when,
   and only when, they appear in all capitals, as shown here.

3. Usage of App-Meta-Data for 5G Edge Computing

  3.1. Assumptions

   From IP Layer, the Application servers are identified by their
   IP (ANYCAST) addresses. Here are some assumptions about the 5G
   Edge Computing services:
     - Only the registered Edge Computing services need special
        consideration in path selection.
     - The 5G Edge Computing controller or management system can
        configure the ACLs to filter out those applications on
        the routers adjacent to the 5G PSA and the routers to
        which the Application servers are directly attached.
     - The ingress routers' local BGP path compute algorithm
        includes a special Plugin that can compute the path to
        the optimal Next Hop (egress router) based on the BGP
        AppMetaData TLV received for the registered Edge
        Computing services.

   The proposed solution is for the egress routers, i.e. A-ER,
   that have direct links to the Application Servers to collect
   various measurements about the Servers' running status [5G-EC-
   Metrics] and advertise the metrics to other routers in 5G EC
   LDN (Local Data Network).

  3.2. IP Layer Metrics to Gauge Application Behavior

Dunbar, et al.        Expires September 8, 2021          [Page 9]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   [5G-EC-Metrics] describes the IP Layer Metrics that can gauge
   the application servers running status and environment:

   - IP-Layer Metric for App Server Load Measurement:
     The Load Measurement to an App Server is a weighted
     combination of the number of packets/bytes to the App Server
     and the number of packets/bytes from the App Server which
     are collected by the A-ER to which the App Server is
     directly attached.
     The A-ER is configured with an ACL that can filter out the
     packets for the Application Server.
   - Capacity Index
     Capacity Index is used to differentiate the running
     environment of the application server. Some data centers can
     have hundreds, or thousands, of servers behind an
     Application Server's App Layer Load Balancer that is
     reachable from an external world. Other data centers can
     have a very small number of servers for the application
     server. "Capacity Index", which is a numeric number, is used
     to represent the capacity of the application server in a
     specific location.
   - Site preference index:
     [IPv6-StickyService] describes a scenario that some sites
     are more preferred for handling an application server than
     others for flows from a specific UE.

   In this document, the term "Application Server Egress Router"
   [A-ER] is used to describe the last router that an Application
   Server is attached. For the 5G EC environment, the A-ER can be
   the gateway router to the EC DC where multiple Application
   servers are hosted.

   From IP Layer, an Application Server is identified by its IP
   (ANYCAST) Address. Those IP addresses are called the
   Application Server IDs throughout this document.

Dunbar, et al.        Expires September 8, 2021         [Page 10]
Internet-Draft    AppMetaData NLRI for 5G EC Service

 3.3. To Equalize among Multiple ANYCAST Locations

   The main benefit of using ANYCAST is to leverage the network
   layer information to equalize the traffic among multiple
   Application Server locations of the same Application, which is
   identified by its ANYCAST addresses.

   For the 5G Edge Computing environment, the ingress routers to
   the LDN need to be notified of the Load Index and Capacity
   Index of the App Servers at different EC data centers to make
   the intelligent decision on where to forward the traffic for
   the application from UEs.

   [5G-EC-Metrics] describes the algorithms that can be used by
   the routers directly attached to the 5G PSA to compare the
   cost to reach the App Servers between the Site-i or Site-j:

               Load-i * CP-j               Pref-j * Delay-i
Cost-i=min(w *(----------------) + (1-w) *(------------------))
              Load-j * CP-i               Pref-i * Delay-j

      Load-i: Load Index at Site-i, it is the weighted
      combination of the total packets or/and bytes sent to and
      received from the Application Server at Site-i during a
      fixed time period.

      CP-i: capacity index at Site-i, a higher value means higher
      capacity.

      Delay-i: Network latency measurement (RTT) to the A-ER that
      has the Application Server attached at the site-i.

      Pref-i: Preference index for the Site-i, a higher value
      means higher preference.

      w: Weight for load and site information, which is a value
      between 0 and 1. If smaller than 0.5, Network latency and
      the site Preference have more influence; otherwise, Server
      load and its capacity have more influence.

 3.4. BGP Protocol Extension to advertise Load & Capacity

    The goal of the protocol extension:

Dunbar, et al.        Expires September 8, 2021         [Page 11]
Internet-Draft    AppMetaData NLRI for 5G EC Service

    - Propagate the Load Measurement Index for the attached App
      Servers to other routers in the LDN.

    - Propagate the Capacity Index &

    - Propagate Site Preference Index.

    The BGP extension is to add the Load Index Sub-TLV, Capacity
    Sub-TLV, and the Site Preference Sub-TLV in the NLRI
    associated with the routes.

 3.5. Ingress Node BGP Path Selection Behavior

 3.5.1. AppMetaData Influenced BGP Path Selection

   In this scenario, an ingress router will receive one ANYCAST
   address's multiple routes from different egress routers that
   have the direct links to the ANYCAST servers. The ingress
   router's BGP engine will do path selection, select the best
   route, and download to FIB. And BGP engine will also download
   the other paths to FIB that with the AppMetaData taken into
   the consideration.

   Assume that both Ra and Rb in Figure 1 have BGP Multipath
   enabled. As a result, Dst Address: S1:aa08::4450 is resolved
   via multiple NextHop: R1, R2, R3.

   Suppose the local BGP special Plugin for AppMetaData finds R1
   is the best for the flow towards S1:aa08::4450. Then this
   special Plugin can insert a higher weight for the path R1 so
   that BGP Best Path is locally influenced by the weight
   parameter based on the local decision.

 3.5.2. Forwarding Behavior

   When the ingress router receives a packet and lookup the FIB,
   get the destination prefix's whole path and AppMetaData. The
   Forwarding Plane will do computing for the packet and choose
   the suitable path as the result of the computing. Then the
   Forwarding Plane encapsulates the packet destined towards the
   optimal Nexthop node.

   For subsequent packets belonging to the same flow, the ingress
   router needs to forward them to the same egress router unless
   the selected egress router is no longer reachable. Keeping
   packets from one flow to the same egress router, a.k.a. Flow
   Affinity, is supported by many commercial routers.

Dunbar, et al.        Expires September 8, 2021         [Page 12]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   How Flow Affinity is implemented is out of the scope for this
   document. Here is one example to illustrate how Flow Affinity
   can be achieved. This illustration is not to be standardized.

     For the registered Edge Computing services, the ingress node
     keeps a table of
     -   Service ID (i.e. ANYCAST address)
     -   Flow-ID
     -   Sticky Egress ID
     -   A timer

     The Flow-ID in this table is to identify a flow, initialized
     to NULL. How Flow-ID is constructed is out of the scope for
     this document. Here is one example of constructing the Flow-
     ID:
       - For IPv6, the Flow-ID can be the Flow-ID extracted from
          the IPv6 packet header with or without the source
          address.
       - For IPv4, the Flow-ID can be the combination of the
          Source Address with or without the TCP/UDP Port number.

     The Sticky Egress ID is to record the egress node address
     that the packets of the same flow that have been forwarded
     to. [5G-Sticky-Service] describes several methods to derive
     the Sticky Egress ID.

     The Timer is always refreshed when a packet with the
     matching ANYCAST address is received by the node.

     If there is no Stick Egress ID present in the table for the
     ANYCAST address, the forwarding plane computes the optimal
     path to a NextHop with the AppMetaData taken into
     consideration. The forwarding plane encapsulate the packet
     with the tunnel to the chosen NextHop. The chosen NextHop
     and the Flow ID are recorded in the table entry of the
     ANYCAST ID.

   When the selected optimal egress router is no longer
   reachable, refer to Section 6 Soft Anchoring on how another
   path is selected.

 3.5.3. Forwarding Behavior after a UE moving to a new 5G Site

   When a UE moves to a new 5G Site, the new ingress router might
   use the pre-computed Egress Router which is passed from the
   neighboring router. [5G-Edge-Sticky] describes the method for
   the ingress router connected to the UPF in the new site to

Dunbar, et al.        Expires September 8, 2021         [Page 13]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   take into consideration the information passed from other
   ingress routers in selecting the optimal egress router. The
   detailed algorithm is out of the scope of this document.

4. The NLRI Path Attribute for App-Meta-Data

   The App-Meta-Data attribute is an optional transitive BGP Path
   attribute to carry application-specific data, such as running
   status, capacity, and site preference.  Will need IANA to
   assign a value as the type code of the attribute.  The
   attribute is composed of a set of Type-Length-Value (TLV)
   encodings.  Each TLV contains information corresponding to
   metrics to a specific Application Server.  An App-Meta-Data
   TLV is structured as shown in Figure 1:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     | AppMetaData Type (2 Octets)   |        Length (2 Octets)      |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     |                             Value                             |
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
              Figure 2: App Meta Data TLV Value Field

   AppMetaData Type (2 octets): identifies a type of Application
   related metadata.  The field contains values from the IANA
   Registry "BGP AppMetaData Types". To be added.

      o  Length (2 octets): the total number of octets of the
   Value field.

      o  Value (variable): comprised of multiple sub-TLVs.

   Each sub-TLV consists of three fields: a 1-octet type, a 1-
   octet or 2-octet length field (depending on the type), and
   zero or more octets of value.  A sub-TLV is structured as
   shown in Figure 2:

Dunbar, et al.        Expires September 8, 2021         [Page 14]
Internet-Draft    AppMetaData NLRI for 5G EC Service

                       +--------------------------------+
                       | Sub-TLV Type (1 Octet)         |
                       +--------------------------------+
                       | Sub-TLV Length (1 or 2 Octets) |
                       +--------------------------------+
                       | Sub-TLV Value (Variable)       |
                       +--------------------------------+

                Figure 3: App Metadata Sub-TLV Value Field

     o  Sub-TLV Type (1 octet): each sub-TLV type defines a
     certain property about the AppMetaData TLV that contains
     this sub-TLV.  The field contains values from the IANA
     Registry "BGP AppMetaData Attribute Sub-TLVs".

     o  Sub-TLV Length (1 or 2 octets): the total number of
     octets of the sub-TLV value field.  The Sub-TLV Length field
     contains 1 octet if the Sub-TLV Type field contains a value
     in the range from 0-127. The Sub-TLV Length field contains
     two octets if the Sub-TLV Type field contains a value in the
     range from 128-255.

     o  Sub-TLV Value (variable): encodings of the value field
     depend on the sub-TLV type as enumerated above. The
     following sub-sections define the encoding in detail.

Dunbar, et al.        Expires September 8, 2021         [Page 15]
Internet-Draft    AppMetaData NLRI for 5G EC Service

4.1. Load Measurement sub-TLV format

   Two types of Load Measurement Sub-TLVs are specified. One is
   to carry the aggregated cost Index based on a weighted
   combination of the collected measurements; another one is to
   carry the raw measurements of packets/bytes to/from the App
   Server address. The raw measurement is useful when the egress
   routers cannot be configured with a consistent algorithm to
   compute the aggregated load index and the raw measurements are
   needed by a central analytic system.

     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |         Type (TBD2)           |               Length          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                   Measurement Period                          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           Aggregated Load Index to reach the App Server       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
              Figure 4: Aggregated Load Index Sub-TLV

   Raw Load Measurement sub-TLV has the following format:

     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           Type (TBD3)         |               Length          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                   Measurement Period                          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           total number of packets to the AppServer            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           total number of packets from the AppServer          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           total number of bytes to the AppServer              |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           total number of bytes from the AppServer            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                  Figure 5: Raw Load Measurement Sub-TLV

     Type =TBD2: Aggregated Load Measurement Index derived from
     the Weighted combination of bytes/packets sent to/received
     from the App server:

     Index=w1*ToPackets+w2*FromPackes+w3*ToBytes+w4*FromBytes

     Where wi is a value between 0 and 1; w1+ w2+ w3+ w4 = 1;

Dunbar, et al.        Expires September 8, 2021         [Page 16]
Internet-Draft    AppMetaData NLRI for 5G EC Service

     Type= TBD3: Raw measurements of packets/bytes to/from the
     App Server address;

     Measure Period: BGP Update period or user-specified period.

  4.2. Capacity Index sub-TLV format

   The Capacity Index sub-TLV has the following format:

      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           Type (TBD4)         |               Length          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                   Capacity Index                              |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Note: "Capacity Index" can be more stable for each site. If
   those values are configured to nodes, they might not need to
   be included in every BGP UPDATE.

  4.3. The Site Preference Index sub-TLV format

   The site Preference Index is used to achieve Soft Anchoring
   [Section 5] an application flow from a UE to a specific
   location when the UE moves from one 5G site to another.

   The Preference Index sub-TLV has the following format:

      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           Type (TBD5)         |               Length          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                   Preference Index                            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Note: "Site Preference Index" can be more stable for each
   site. If those values are configured to nodes, they might not
   need to be included in every BGP UPDATE.

Dunbar, et al.        Expires September 8, 2021         [Page 17]
Internet-Draft    AppMetaData NLRI for 5G EC Service

5. AppMetaData Propagation Scope

   AppMetaData is only to be distributed to the relevant ingress
   nodes of the 5G Edge Computing local data networks. Only the
   ingress routers that are configured with the 5G Edge Computing
   services ACLs need to receive the AppMetaData for specific
   services.

   For each registered Edge Computing service, a corresponding
   filter group can be formed on RR to represent the interested
   ingress routers that are interested in receiving the
   corresponding AppMetaData information.

6. Soft Anchoring of an ANYCAST Flow
   "Sticky Service" in the 3GPP Edge Computing specification
   (3GPP TR 23.748) requires a UE to a specific ANYCAST location
   when the UE moves from one 5G Site to another.

   "Soft Anchoring" is referring to forwarding the Application
   flow from a UE to a preferred location of the ANYCAST servers
   when the preferred location is in good condition. But if
   there is any failure reaching the preferred location, the
   Application flow from the UE will be forwarded to another
   location of the ANYCAST servers.

   This section describes a solution that can softly anchor an
   application flow from a UE to a preferred location.

   Lets' assume one application "App.net" is instantiated on
   four servers that are attached to four different routers R1,
   R2, R3, and R4 respectively. It is desired for packets to the
   "App.net" from UE-1 to stick with one server, say the App
   Server attached to R1, even when the UE moves from one 5G
   site to another. When there is a failure reaching R1 or the
   Application Server attached to R1, the packets of the flow
   "App.net" from UE-1 need to be forwarded to the Application
   Server attached to R2, R3, or R4.

   We call this kind of sticky service "Soft Anchoring", meaning
   that anchoring to the site of R1 is preferred, but other
   sites can be chosen when the preferred site encounters a
   failure.

   Here are the details of this solution:

Dunbar, et al.        Expires September 8, 2021         [Page 18]
Internet-Draft    AppMetaData NLRI for 5G EC Service

      - Assign a group of ANYCAST addresses to one application.
        For example, "App.net" is assigned with 4 ANYCAST
        addresses, L1, L2, L3, and L4. L1/L2/L3/L4 represents
        the location preferred ANYCAST addresses.
      - For the App.net Server attached to a router, the router
        has four Stub links to the same Server, L1, L2, L3, and
        L4 respectively. The cost to L1, L2, L3, and L4 is
        assigned differently for different routers. For example,
           o When attached to R1, the L1 has the lowest cost,
             say 10, when attached to R2, R3, and R4, the L1 can
             have a higher cost, say 30.
           o ANYCAST L2 has the lowest cost when attached to R2,
             higher cost when attached to R1, R3, R4
             respectively.
           o ANYCAST L3 has the lowest cost when attached to R3,
             higher cost when attached to R1, R2, R4
             respectively, and
           o ANYCAST L4 has the lowest cost when attached to R4,
             higher cost when attached to R1, R2, R3
             respectively
      - When a UE queries for the "App.net" for the first time,
        the DNS reply has the location preferred ANYCAST
        address, say L1, based on where the query is initiated.
      - When the UE moves from one 5G site-A to Site-B, UE
        continues sending packets of the "App.net" to ANYCAST
        address L1. The routers will continue sending packets to
        R1 because the total cost for the App.net instance for
        ANYCAST L1 is lowest at R1. If any failure occurs making
        R1 not reachable, the packets of the "App.net" from UE-1
        will be sent to R2, R3, or R4 (depending on the total
        cost to reach each of them).

   If the Application Server supports the HTTP redirect, more
   optimal forwarding can be achieved.

      - When a UE queries for the "App.net" for the first time,
        the global DNS reply has the ANYCAST address G1, which

Dunbar, et al.        Expires September 8, 2021         [Page 19]
Internet-Draft    AppMetaData NLRI for 5G EC Service

        has the same cost regardless of where the Application
        servers are attached.
      - When the UE initiates the communication to G1, the
        packets from the UE will be sent to the Application
        Server that has the lowest cost, say the Server attached
        to R1. The Application server is instructed with HTTPs
        Redirect to reply with a location-specific URL, say
        App.net-Loc1. The client on the UE will query the DNS
        for App.net-Loc1 and get the response of ANYCAST L1. The
        subsequent packets from the UE-1 for App.net are sent to
        L1.

7. Manageability Considerations

     To be added.

8. Security Considerations

   To be added.

9. IANA Considerations

       To be added.

10. References

  10.1. Normative References

   [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
             Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC4364] E. rosen, Y. Rekhter, "BGP/MPLS IP Virtual Private
             networks (VPNs)", Feb 2006.

   [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in
             RFC 2119 Key Words", BCP 14, RFC 8174, DOI
             10.17487/RFC8174, May 2017, <https://www.rfc-
             editor.org/info/rfc8174>.

Dunbar, et al.        Expires September 8, 2021         [Page 20]
Internet-Draft    AppMetaData NLRI for 5G EC Service

   [RFC8200] s. Deering R. Hinden, "Internet Protocol, Version 6
             (IPv6) Specification", July 2017

  10.2. Informative References

   [3GPP-EdgeComputing] 3GPP TR 23.748, "3rd Generation
             Partnership Project; Technical Specification Group
             Services and System Aspects; Study on enhancement of
             support for Edge Computing in 5G Core network
             (5GC)", Release 17 work in progress, Aug 2020.

   [5G-EC-Metrics] L. Dunbar, H. Song, J. Kaippallimalil, "IP
             Layer Metrics for 5G Edge Computing Service", draft-
             dunbar-ippm-5g-edge-compute-ip-layer-metrics-00,
             work-in-progress, Oct 2020.

   [5G-Edge-Sticky] L. Dunbar, J. Kaippallimalil, "IPv6 Solution
             for 5G Edge Computing Sticky Service", draft-dunbar-
             6man-5g-ec-sticky-service-00, work-in-progress, Oct
             2020.

   [RFC5521] P. Mohapatra, E. Rosen, "The BGP Encapsulation
             Subsequent Address Family Identifier (SAFI) and the
             BGP Tunnel Encapsulation Attribute", April 2009.

   [BGP-SDWAN-Port] L. Dunbar, H. Wang, W. Hao, "BGP Extension
             for SDWAN Overlay Networks", draft-dunbar-idr-bgp-
             sdwan-overlay-ext-03, work-in-progress, Nov 2018.

   [SDWAN-EDGE-Discovery] L. Dunbar, S. Hares, R. Raszuk, K.
             Majumdar, "BGP UPDATE for SDWAN Edge Discovery",
             draft-dunbar-idr-sdwan-edge-discovery-00, work-in-
             progress, July 2020.

   [Tunnel-Encap] E. Rosen, et al "The BGP Tunnel Encapsulation
             Attribute", draft-ietf-idr-tunnel-encaps-10, Aug
             2018.

Dunbar, et al.        Expires September 8, 2021         [Page 21]
Internet-Draft    AppMetaData NLRI for 5G EC Service

11. Acknowledgments

   Acknowledgements to Donald Eastlake for their review and
   contributions.

   This document was prepared using 2-Word-v2.0.template.dot.

Authors' Addresses

   Linda Dunbar
   Futurewei
   Email: ldunbar@futurewei.com

   Kausik Majumdar
   CommScope
   350 W Java Drive, Sunnyvale, CA 94089
   Email:  kausik.majumdar@commscope.com

   Haibo Wang
   Huawei
   Email: rainsword.wang@huawei.com

Dunbar, et al.        Expires September 8, 2021         [Page 22]