Re: [Detnet] Last Call: <draft-ietf-detnet-yang-18.txt> (Deterministic Networking (DetNet) YANG Model) to Proposed Standard

Don Fedyk <dfedyk@labn.net> Tue, 19 December 2023 21:19 UTC

Return-Path: <dfedyk@labn.net>
X-Original-To: detnet@ietfa.amsl.com
Delivered-To: detnet@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 7E423C330518; Tue, 19 Dec 2023 13:19:18 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.91
X-Spam-Level:
X-Spam-Status: No, score=-1.91 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_BLOCKED=0.001, RCVD_IN_MSPIKE_H2=-0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=labn.onmicrosoft.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id f2y8tdoGZZ9X; Tue, 19 Dec 2023 13:19:14 -0800 (PST)
Received: from NAM10-MW2-obe.outbound.protection.outlook.com (mail-mw2nam10on2112.outbound.protection.outlook.com [40.107.94.112]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id AFF58C032116; Tue, 19 Dec 2023 13:19:13 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FJ5WGVlPwzb6Fqc8Sd2dceD1Hu+WAbR1hArh+i+jgA7MGpBfljDUXOTFxfosx6LlzAKhZ0cM8+AWbv198z67VSxO3PROr072N1EaqR8oNjOm94XHFxpDgejFIWq7gmJDX1CL7esBrJRrPZGdmNOsn6hJx+hVc6iCBRMQi3N/qDJ+TuxHA6eivbpzadzztIl1WIKnWA4iKu163FBeFJz8ulgBCKJFnnqowrGvxrqNrUUs1C/3vlSSf9J021kbOVXmV747NZUKGnZkG8w2def4Ci8+6yDR2kc5QVylbsQnnSeaWNzIALVrjKl6CWcRkMsV5kgh+NZPX95LakHK40e81w==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=xvN/HQCmgt13D0QwpDBN9sKWAMPUjMv8wm1P5M2or9Q=; b=igdMu/FwhB9q7a4AXS2WOFPz+pzceA+bfNXNqcaCF7+RP8IjvDRdoSNjzqvKIC7QDtIL0OAY8ghbmvWYjw6jdkbSSw2Hew7RnICp/MWBiCVyYCdVqYOYPoEXk5gkblthpw3zk8Bmwr0eitpaZlnn8QJiySxuKoGPXqoU1AtIgJ2nqTw58NXp9EVWYU5NQzZ3NKxR/ShN5wMe/Ai0JchRyXS3lR7p6qT4sASna2bQlmOCib52QbKOepfcRgGUy3Mg+FJhFe7cjY8SpDgS8lSR58wNBiKqVxBqZ+SIoXt32rVfalQ8/+TdcWnKDONAwIXo2jnhCFf84VUPWCsc7AS6PQ==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=labn.net; dmarc=pass action=none header.from=labn.net; dkim=pass header.d=labn.net; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=labn.onmicrosoft.com; s=selector2-labn-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xvN/HQCmgt13D0QwpDBN9sKWAMPUjMv8wm1P5M2or9Q=; b=u5GSItjetjqCJEg+Lmj+1YZcuVfVKVsYFm/GdEpEe5JBZ2bbjZtigZkVcctt8yLojqyi3Vay/kl6WnUiDlbVYqVZFTzA5m7SInxxZyuGC2BCPYP+xQvTSB5vDd+Kro9Ffv/2v7/WXb4o0CCHmE0RiSRMI1swbqHzon5gdVD9w+A=
Received: from PH7PR14MB5368.namprd14.prod.outlook.com (2603:10b6:510:133::11) by MN2PR14MB4142.namprd14.prod.outlook.com (2603:10b6:208:1d5::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7091.38; Tue, 19 Dec 2023 21:19:09 +0000
Received: from PH7PR14MB5368.namprd14.prod.outlook.com ([fe80::3f34:5ede:37ef:b665]) by PH7PR14MB5368.namprd14.prod.outlook.com ([fe80::3f34:5ede:37ef:b665%5]) with mapi id 15.20.7091.034; Tue, 19 Dec 2023 21:19:09 +0000
From: Don Fedyk <dfedyk@labn.net>
To: Florian Kauer <florian.kauer@linutronix.de>, "last-call@ietf.org" <last-call@ietf.org>, "draft-ietf-detnet-yang@ietf.org" <draft-ietf-detnet-yang@ietf.org>
CC: "detnet-chairs@ietf.org" <detnet-chairs@ietf.org>, "detnet@ietf.org" <detnet@ietf.org>, "janos.farkas@ericsson.com" <janos.farkas@ericsson.com>, "jgs@juniper.net" <jgs@juniper.net>
Thread-Topic: [Detnet] Last Call: <draft-ietf-detnet-yang-18.txt> (Deterministic Networking (DetNet) YANG Model) to Proposed Standard
Thread-Index: AQHaJ7UoE2DamHhYVkWp/qef7C5NO7CcPtiAgBSxiwA=
Date: Tue, 19 Dec 2023 21:19:09 +0000
Message-ID: <PH7PR14MB536872E10E81EE003BA11E23BB97A@PH7PR14MB5368.namprd14.prod.outlook.com>
References: <170180619452.981.2657917158901639039@ietfa.amsl.com> <01caf93f-efdf-4293-89fd-e296cd3465f9@linutronix.de>
In-Reply-To: <01caf93f-efdf-4293-89fd-e296cd3465f9@linutronix.de>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=labn.net;
x-ms-publictraffictype: Email
x-ms-traffictypediagnostic: PH7PR14MB5368:EE_|MN2PR14MB4142:EE_
x-ms-office365-filtering-correlation-id: 2e03a517-3982-418c-11f3-08dc00d823b5
x-ms-exchange-senderadcheck: 1
x-ms-exchange-antispam-relay: 0
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: vqk3VQMhhKGkWWkDp3wGWJ0VJ5rIfLEBmf9pTSTtIx01CnCwhC1tfhN1gs5SgEzg3LBZB0hX11aR8G3dVoTMfkQkmI4jH6KFeU0/XZ5E6EQ+InL6EX+0Fa7UL+IkO0Uz1RSw+QTnH3gmewI6ELri+lq7+Dj+ibdxM89hkb77U5OVDV7FmQlHmFI8yIxP5wbVVB/8XI/83pVy38UPu3qFibhKgtDk6MUNgWhgVJhwyj/Hu0QTXZGvibVjG9s8wF4LuiKYebvysluA/+JZB2mQnRwkbi5ti077Z055e7CTzPHTY5ilfb3Cw2UTeslra0oPnoC+SMPGbqxQKyTzIGqi0oxLVeoangASTgMUv393W3BJdQZvWAgCu4yzMdzM4RXv+aWYUYmH3RsJDeOopVkLTmjKAMnd+CB/oDGGOHXpZ7A0PDBtTkZE9+fO3AEthwA71m4AACctRrEiCHwgbQZ7Rnam+xeyB29Pho+AV/RZoJz2DefZcIyLpLPdRo/A+JIFS3NR/4pn6kkes3x8TsWSfF1oq7nFMM4Fy8cjXSoypPMqTu+zcAMSp4S1oVDlLdLooNdvAxEVjyXeeQfaU9gg7ZpXhJ0sjCTPcNqx9+80tArCrloJbkfRf9Sf5g0IYFNa
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH7PR14MB5368.namprd14.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(366004)(346002)(136003)(396003)(376002)(39830400003)(230922051799003)(64100799003)(451199024)(186009)(1800799012)(110136005)(478600001)(64756008)(450100002)(66476007)(66446008)(66556008)(54906003)(4326008)(316002)(52536014)(8676002)(66946007)(8936002)(86362001)(38070700009)(76116006)(41300700001)(5660300002)(2906002)(30864003)(33656002)(38100700002)(83380400001)(122000001)(53546011)(7696005)(71200400001)(6506007)(9686003)(26005)(107886003)(55016003); DIR:OUT; SFP:1102;
x-ms-exchange-antispam-messagedata-chunkcount: 1
x-ms-exchange-antispam-messagedata-0: lIYtdMXZx1DBnrTZXFJjkQYY07AJRUOFuMEWp+CNKr6uTpYhulb2ilDXT6vHQpKQaGZxF5pegr46glU3Q8GBKygPKwawYRd+f+pUjQ+m6GOzemKKjFqofXjikds/VM295JzULKfGe5nzpEaXXON6XH6HELt1dBEg0WQ+UoCU1bK0x1isyFfHUtpXxfxzn0iLVYDitoNjt+OXFU8ovmPuABNBHfxbkX/JszRqSmmIPgNJFm5l1VV4aMsAeTwzVnHZepeBtzJwzywfm7wvsvJjgpIARVY/rJGrRRFhhKm7nPiX+y3nIuoZHoGSP2cRQPhFOGLDqpgnyRzHM0J07CIRCHoigM4YRYnkfR3qFovSAkbAOwxIMM2yKXabQBcQW/s7DeXEx3pCG9aXC/giUCv9DChLU5jAJDUoS7YPZxRG1Xryj/3479dHS05kYleX1EX3/DXEncpvWaXFXEWFTz9doC0U7NwLqijfKCv2G/Xc1Y6tjgsKqUEEQ98E+DB15vQLQefb6VyS96A2HQI2Q+fRTjqQWPf00BkdZMNeuN5IFadrBdNgmXU81NMgCJOvZAGiBDkT30547suv+9JbSqs/i2IQkw1N9L98HMzKgkerFkvM98ffXGo/lkSrnCrBfn2N/eVI/xTbIftri9ImcVCckt/PgTbsWqEBozLmhdlNkxlh280t/xonAyDloa9H7/7skjMUiVfNmRwaJEX7QkhCOSuxw+YxfKgOKfcu7MJb53BviiBMUDfh1XFQjUvxbrcDL1gL8VZYyIBgirwwf/yUhPWih2ETeFjOwVET6aePAsvkhfK/SaoGofLXe3B2jPg1liAk8vDAmyLwbuSZd64aUBSFudzBPL2eOn5aMr0WHV5Yo7qcqslk/IDvBplpDIpkuzN4g8/7UvW7cj8MzZoM6c339wObVqMxYON11TyhHbRS8EHIlUYPaKsKwdvF+CTfnf6yOxMManEQt1eB/c4ccxZmSqki4V/uhdbV/GYdLzLdtV2aniw3A02LUm3DWfyMczwIPrtQm07/TfsV2lqELd9zpB4aSJZEPIvVJxkWlJjXPs82o2/lGmH5olmN4CwrwQitwvOWd3/03EeNIaDolEhWkRDguxCFX78YkpqlfcJCP6JL7dL6zK7E0urbIfj4PQXky6zJJXV+sBBbwBjqki55OCSK7IOijwKGwJa7hfM9PDzRuSNnlq//RwFbJmremiY0EwCpVyzSe/R5Sxl7UJABxvezYH98sJ444ohCo8bJqTFAzl7wNvH+mcYWe9Gm7xRHkxu3tn4Mb0pur/RQKjKfiMIEBwukANESoLz1Gc0ZV+NM8b15SdRFXKoBxD1h9TBO6tr1RHdayNG+WaviW1IFmOteHglsVSOdRPoeEv/p+wA8rCr5SRjOV97JWfW6w65hFlA5jHOqraeVe8JqfiIv3SomPnq3AA9uBtx4rql7+L/St7HznUsidYAvu4CBBaHSBsCMaewlYrCp4w67znyYCJApGZeII8rZAI7Me8dqBMAJB+HFSWbjI69qpfC7V/9jz5LXv2a6lVuuvB1B2nupM8cllD+G1XZ7X9FY2pj8QRl9J5w0bmNATaYEIYUc
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-OriginatorOrg: labn.net
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: PH7PR14MB5368.namprd14.prod.outlook.com
X-MS-Exchange-CrossTenant-Network-Message-Id: 2e03a517-3982-418c-11f3-08dc00d823b5
X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Dec 2023 21:19:09.1336 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: eb60ac54-2184-4344-9b60-40c8b2b72561
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: eYFMBtigCQXS8ZlH4C4UcJPc0daXPda2YxmUVlex7nAaw43cp8sc+3BmgmN/L6dY8hcUazUa908XnDx1Jobfjw==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR14MB4142
Archived-At: <https://mailarchive.ietf.org/arch/msg/detnet/frrbSYj-HiG2dECWHUbeN9eV94U>
Subject: Re: [Detnet] Last Call: <draft-ietf-detnet-yang-18.txt> (Deterministic Networking (DetNet) YANG Model) to Proposed Standard
X-BeenThere: detnet@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Discussions on Deterministic Networking BoF and Proposed WG <detnet.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/detnet>, <mailto:detnet-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/detnet/>
List-Post: <mailto:detnet@ietf.org>
List-Help: <mailto:detnet-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/detnet>, <mailto:detnet-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 19 Dec 2023 21:19:18 -0000

Hi Florian 

Thank you for your review, 
Inline comments [Don] are my comments. 
There are three categories of my responses: 
- OK will adopt your change. 
- A comment - clarification - Not sure any action is necessary. See responses below.
- An update addressing a point in the text - action on me.  I will produce an update and respond with an email to this thread with the propose updated text for you and co-authors and others to review. 

That will take a couple days. 

Cheers
Don & co authors.

-----Original Message-----
From: Florian Kauer <florian.kauer@linutronix.de> 
Sent: Wednesday, December 6, 2023 8:22 AM
To: last-call@ietf.org; draft-ietf-detnet-yang@ietf.org
Cc: detnet-chairs@ietf.org; detnet@ietf.org; janos.farkas@ericsson.com; jgs@juniper.net
Subject: Re: [Detnet] Last Call: <draft-ietf-detnet-yang-18.txt> (Deterministic Networking (DetNet) YANG Model) to Proposed Standard

Hi,
sorry for being this late, but there are several things that still confuse me when I try to apply the YANG model in a TSN over IP over TSN scenario (i.e. using DetNet to connect several TSNs over IP tunnels in the industrial automation or professional audio context).

It is likely that my confusions are only based on misunderstandings and missing background knowledge (and that's I why I did not speak up before and tried to do more research first), but I still would like to raise them now and let others decide if they are valid concerns or not. In both cases, I still would love to get support clarifying these points.

I also fixed some things that look like typos to me, but take them with a grain of salt since I am not a native speaker.

Greetings,
Florian

--- draft-ietf-detnet-yang-18.txt       2023-07-10 21:24:35.000000000 +0200
+++ draft-ietf-detnet-yang-18-fk-comments.txt   2023-12-06 13:49:42.692711093 +0100
@@ -192,14 +192,14 @@
    |  r  |Forwarding S-L   |Forwarding S-L   | Forwarding S-L|
    +-----+-----------------+-----------------+---------------+
 
-                   Figure 1: Detnet Layers and Node Types
+                   Figure 1: DetNet Layers and Node Types
[Don] OK.
 
    All of the layers have ingress/incoming and egress/outgoing
    operations, but any instance may be configured as only
    unidirectional.  Ingress refers to any DetNet layer where a DetNet
    context is applied.  Ingress allows functions such as switching,
    aggregation and encapsulation.  Likewise, egress refers to any DetNet
-   layer where a Detnet context is removed.  Egress allows functions
+   layer where a DetNet context is removed.  Egress allows functions
    such as switching, disaggregation and decapsulation.  This means that
    each unidirectional flow identifier configuration is programmed
    starting at the ingress and flow status is reported at ingress on @@ -454,7 +454,7 @@
[Don] OK.
    This YANG model imports typedefs from [RFC6991], [RFC8519],
    [RFC8294], [RFC8343], [IEEE8021Q], and [IEEE8021QCX].  This YANG
-   model also has the folowing references to RFCs that are not in the
+   model also has the following references to RFCs that are not in the
    document text body [RFC0791], [RFC4303], [RFC8349], [RFC8938],
    [RFC8960], [RFC8964], and [RFC8200].
[Don] OK.
 
@@ -583,7 +583,7 @@
      identity none {
        base app-status;
        description
-         "This Application has no status. This identity is
+         "This application has no status. This identity is
[Don] OK.
           expected when the configuration is incomplete.";
        reference
          "RFC 9016 Section 5.8";
@@ -600,7 +600,7 @@
      identity failed {
        base app-status;
        description
-         "Application ingres/egress failed.";
+         "Application ingress/egress failed.";\
[Don] OK.
        reference
          "RFC 9016 Section 5.8";
      }
@@ -608,7 +608,7 @@
      identity out-of-service {
        base app-status;
        description
-         "Application Administratively blocked.";
+         "Application administratively blocked.";
[Don] OK.
        reference
 
 
@@ -624,7 +624,7 @@
      identity partial-failed {
        base app-status;
        description
-         "This is an Application with one or more Egress ready, and one
+         "This is an application with one or more Egress ready, and one
[Don] OK.
           or more Egress failed.  The DetNet flow can be used if the
           Ingress is Ready.";
        reference
@@ -639,7 +639,7 @@
             + "/dnet:name";
        }
        description
-         "This is an Application Reference.";
+         "This is an application reference.";
      }
 
[Don] OK.
      typedef service-sub-layer-ref {
@@ -650,7 +650,7 @@
             + "/dnet:name";
        }
        description
-         "This is a Service sub-layer Reference.";
+         "This is a service sub-layer reference.";
      }
[Don] OK.
      typedef forwarding-sub-layer-ref { @@ -661,7 +661,7 @@
             + "/dnet:name";
        }
        description
-         "This is a Forwarding sub-layer Reference.";
+         "This is a forwarding sub-layer reference.";
      }
[Don] OK. 
      typedef traffic-profile-ref {
@@ -679,7 +679,7 @@
             + "/dnet:name";
        }
        description
-         "This is a Traffic Profile Reference.";
+         "This is a traffic profile reference.";
      }
[Don] OK. 
      typedef ipsec-spi {
@@ -1113,6 +1113,79 @@
          description
            "The Application flow type choices.";
          container tsn-app-flow {
+---
+fk: In case of a tsn-app-flow, how does the actual encapsulation take place?

[Don] This is a YANG specification that satisfies the operations in DetNet RFCs  
Listed in the references.  You can think of it as a configuration for an 
SDN controller that specifies encapsulation/decapsulation on various nodes/devices
along the data path. It is not specifying "how" it is specifying "what" aggregation,  
disaggregation functions are applied along the data path and which technology is used.

Also reading through your comments I think there is mis understanding.  

DetNet is not an any to any encapsulation. It is specifically what is covered in the DetNet architecture to support DetNet encapsulation flows for aggregation or replication.  We have specific type of encapsulations and behaviors that must be specified on ingress. The reverse operations don’t need as much specification because you are removing an outer encapsulation and exposing another header. I will try to see if this point is spelled out in the ID. 
  
+
+For reference, lets look at a few cases and how I have understood them:
+
+1. ip-app-flow, nothing MPLS related in service or forwarding sub-layers:
+   -> Just transmit unmodified packet with new L2 header.
++---------------+      +----------+
+| Payload       |      | Payload  |
++---------------+      +----------+
+|   UDP         |      |   UDP    |
++---------------+  ->  +----------+
+|   IP          |      |   IP     |
++---------------+      +----------+
+| L2 (original) |      | L2 (new) |
++---------------+      +----------+

[Don]  Is this is a DetNet Appflow?  Please see DetNet Architecture RFC 8655 Figure 3. Also Data Plane Framework RFC8938.
We are only concerned with DetNet.

The drawing is a bit ambiguous for DetNet.  
The Payload could be the TSN flow then the IP is a DetNet sub-network and you have a DetNet packet. The L2 is irrelevant.  
If the whole stack Payload/UDP/IP is a TSN payload then TSN is the subnetwork layer. It would be a TSN application frame in ingress and the SAME frame on egress.    

The YANG model aggregates (encapsulates) and disaggregates (decapsulates) DetNet packet but it does not change/translate a TSN L2.  The encapsulation layers for DetNet are IP/MPLS not Ethernet L2.   (we don’t specify egress L2 headers we can match L2 ingress headers at the Application interface).  
      

+
+2. ip-app-flow, but MPLS label is added:
+   -> Squeeze in MPLS header.
++---------------+      +----------+
+| Payload       |      | Payload  |
++---------------+      +----------+
+|   UDP         |      |   UDP    |
++---------------+  ->  +----------+
+|   IP          |      |   IP     |
++---------------+      +----------+
+| L2 (original) |      |   MPLS   |
++---------------+      +----------+
+                       | L2 (new) |
+                       +----------+
[Don] Again if this is an IP App flow you have this. L2 Not relevant.

++---------------+      +----------+
+| Payload       |      | Payload  |
++---------------+      +----------+
+|   UDP         |      |   UDP    |
++---------------+  ->  +----------+
+|   IP          |      |   IP     |
++---------------+      +----------+
                        |   MPLS   |
                        +----------+

[Don] Or if it is TSN app flow you have this: 

++---------------+      +----------+
+| Payload       |      | Original |
++---------------+      | L2 Frame |
+|   UDP         |      |          |
++---------------+  ->  |          |
+|   IP          |      |          |
++---------------+      |          |
+| L2 (original) |      |          |
++---------------+      +---------------------------+
+                       | DetNet Service Sublayer|  |
+                       +---------------------------+
+                       | DetNet Forwarding Sublayer|  |
+                       +---------------------------+                        
 

+
+3. mpls-app-flow:
+   -> Only optionally modify MPLS header
++-----------------+      +------------+
+| Payload         |      | Payload    |
++-----------------+      +------------+
+|   UDP           |      |   UDP      |
++-----------------+  ->  +------------+
+|   IP            |      |   IP       |
++-----------------+      +------------+
+| MPLS (original) |      | MPLS (new) |
++-----------------+      +------------+
+| L2 (original)   |      | L2 (new)   |
++-----------------+      +------------+


[Don] If it is an APP flow it gets encapsulated. We can encapsulate service sub-layer as application layer for example.  This header format could also be a service sub layer and we show examples of changing the labels as a serve sub layer and forwarding layer.   

+
+4. tsn-app-flow:
+   -> In order to be able to reconstruct the full original L2 packet, we need
+      to retain the L2 header. So we need something like:
+
++---------------+      +-----------------+
+| Payload       |      |    Payload      |
++---------------+  ->  +-----------------+
+| L2 (Original) |      |  L2 (Original)  |
++---------------+      +-----------------+
+                       |      ???        |
+                       +-----------------+
+                       |   L2 (new)      |
+                       +-----------------+

[Don] This is specified in IEEE TSN.    DetNet uses IP/MPLS as the service sub layer. 
+
+I know there are several different ways to realize this, including just 
+transmitting the L2 packet over MPLS (apparently not IETF 
+standardized?) or several others like L2TPv3 (RFC3931) or VXLAN (RFC 
+7348) if no MPLS labels are to be added (like in case 1 above).

+
+I would expect the YANG model (either this or a linked one) to somehow 
+specify which of these options shall actually be applied. Otherwise, 
+two DetNet routers might not be able to communicate with each other, 
+because one might use L2TPv3 and the other one VXLAN. And also for 
+example in the case of VXLAN, we would need the option to specify a VXLAN Network Identifier.

[Don] The scope of the YANG does what DetNet documents outline. There is no VXLAN or L2TP3 specified in the DetNet when this applied. 
The DetNet YANG works by specified the whole path and applying the appropriate encapsulation format at the appropriate places. Yes the encapsulation specified on each device must match just the way SDN controllers specify packet forwarding in several technologies.



+
+What do you think about that?
+
+---
            uses l2-header;
 
 
@@ -1143,7 +1216,7 @@
          "detnet-flow identification.";
        choice detnet-flow-type {
          description
-           "The Detnet flow type choices.";
+           "The DetNet flow type choices.";
          case ip-detnet-flow {
            uses ip-flow-id;
          }
[Don] OK
@@ -1254,7 +1327,7 @@
              case mpls {
                uses rt-types:mpls-label-stack;
                description
-                 "The MPLS Label stack next hop case.";
+                 "The MPLS label stack next hop case.";
              }
            }
          }
[Don] OK
@@ -1425,6 +1498,9 @@
            type string;
            description
              "An Aggregation group ID.";
+---
+fk: I would expect "The name of the traffic profile." here as it is similarly used for most other names.
+---
[Don] Looks like a copy paste error. Will fix. 
          }
          container traffic-requirements {
            description
@@ -1708,10 +1784,20 @@
            container egress {
              description
                "Route's next-hop attribute.";

[Don] This should read "Egress DetNet application flows or a compound flow
+---
+fk: This description does not seem right at this place!?
+---
              uses data-flow-spec;
              choice application-type {
                description
                  "This is the application type choices.";
+---
+fk: This part is quite confusing to me, especially since it does not directly mirror the ingress since.
+I guess one reason for that is there could be multiple interfaces that could be selected based on the packet headers?
+But for the same reason you could also have multiple ingress interfaces.
[Don]  For Egress the options are different because we get here by decapsulating the service sub-layer. We have either some type of TSN frame (Ethernet) or IP/MPLS but we are basically only associating the flow with an interface at the end of a service sub-layer.  
 
+Also the "ethernet" application type is confusing. I would expect that 
+it should mirror the "tsn-app-flow", but then it mentions "TSN unaware traffic"?
+---
[Don] We have used TSN and ethernet interchangeably - I will review for consistency. 

                container ethernet {
                  description
                    "This is TSN unaware traffic that maps to an @@ -1860,6 +1946,9 @@
                container forwarding-sub-layer {
                  description
                    "This service sub-layer is sent to the forwarding
+--
+fk: "sent" or "sending"?
+--
[Don] Sending is better. 
                     sub-layers of the lower layer for DetNet service
                     forwarding or service-to-forwarding aggregation at
                     the ingress node or relay node.  When the operation @@ -1978,7 +2067,11 @@
          list sub-layer {
            key "name";
            description
-             "The List is one or more DetNet Traffic types.";
+             "The list is one or more DetNet traffic types.";
+---
+fk: I don't get the meaning of this sentence in this context!?
+This is the forwarding sub-layer name and not a traffic type!?
[Don] I think "The list is one or more DetNet service/forwarding types". Is more accurate.
+---
            leaf name {
              type string;
              description
@@ -1996,6 +2089,9 @@
                 impose-and-forward, pop-and-forward,
                 pop-impose-and-forward, forward, pop-and-lookup.";
            }
+---
+fk: Since these are MPLS forwarding-operations, do we still use e.g. "forwarding" when using IP instead of MPLS or just leave this out?
+---
[Don] This is an optional operation that applies only to MPLS forwarding.  I suppose the type mpls-forwarding-operation or mpls-fwd-operation might be a more accurate name that just forwarding operation. 

            container incoming {
              description
                "The DetNet forwarding sub-layer incoming @@ -2206,9 +2302,18 @@
    be considered sensitive.
 
    /detnet/traffic-profile/member-app: This links traffic profiles to
-   applications, o this also could be considered more sensitive.  The
+   applications, so this also could be considered more sensitive.  The
    traffic profiles liked to service sub-layer and forwarding sub-layer
    are less sensitive.
+---
+fk: I am not so sure if that is the case. Being able to change a 
+traffic profile could mean that you can for example change a DetNet 
+flow that is specified as lossless into one that is lossy. Or one with 
+a very small latency into one with a huge latency.
+If the DetNet flow carries data of a time-critical industrial control 
+loop, I wouldn't be too happy if an attacker can occasionally crash my 
+system by dropping packets or inducing additional latencies.
+---
[Don] I will have to check this wording.
 
    /detnet/service/sub-layer/incoming/app-flow: This links applications
    to services.
@@ -2608,6 +2713,14 @@
         |     +--rw operation?            operation
         |     +--rw incoming
         |     |  +--rw (incoming)?
+---
+fk: One thing I raised before, but it either my comment got lost or i missed the response:
+Why is there no incoming forwarding sub-layer for the service sub-layer?
+An app-flow has outgoing service-sub-layer and incoming 
+service-sub-layer, a forwarding sub-layer has incoming 
+service-sub-layer and outgoing service-sub-layer, a service sub-layer 
+has incoming app-flow and outgoing app-flow and it has outgoing forwarding sub-layer, but NO incoming forwarding sub-layer.
[Don] Sorry I missed your comment before.   
The operation of Service-sub-layer to forwarding sub-layer is an association of an encapsulation operation. The reverse direction is simply a removal of the forwarding layer and a match in the now exposed service Sub-layer.  Therefore, you do not need the same level of description.


+---
         |     |     +--:(app-flow)
         |     |     |  +--rw app-flow
         |     |     |     +--rw flow*   app-flow-ref
@@ -2976,7 +3089,7 @@
       by the configuration.
 
    The following are examples of aggregation and disaggregation at
-   various points in Detnet.  Figures are provided in the PDF and HTML
+   various points in DetNet.  Figures are provided in the PDF and HTML
[Don] OK
    version of this document.
 
 B.1.  Example A-1 JSON Configuration/Operational