Re: [Teas] Yangdoctors early review of draft-ietf-teas-yang-te-types-01

"Tarek Saad (tsaad)" <> Thu, 17 January 2019 16:15 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 6D52C130E8D; Thu, 17 Jan 2019 08:15:54 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -14.642
X-Spam-Status: No, score=-14.642 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_MED=-0.142, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, SPF_PASS=-0.001, USER_IN_DEF_DKIM_WL=-7.5] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (1024-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id yMlW8hnRZC5f; Thu, 17 Jan 2019 08:15:51 -0800 (PST)
Received: from ( []) (using TLSv1.2 with cipher DHE-RSA-SEED-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 8BD80130E8A; Thu, 17 Jan 2019 08:15:50 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;;; l=66788; q=dns/txt; s=iport; t=1547741750; x=1548951350; h=from:to:cc:subject:date:message-id:references: in-reply-to:mime-version; bh=ORQL7NVveDXzrcaogkQN5SZbDK2vegDYbYbgSeup7U8=; b=ZD3r4UlMv3atC5XO98U2KgLsdb1qxkF3CyuCnTiLb8Nkptl8KQLNVPoJ QcZjDEGbBs7kjY6FeGERndQ2kwC0I2hIFA3iqMDdtCEsvMs4Bl9qgqZdG i8QNKHmkrnC/CUWcxRS3OFgVH4PrPBTyAYct63BstS7u0N5e/W4Iik3Gp 4=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0BDAADpqUBc/4ENJK1ZAQkZAQEBAQE?= =?us-ascii?q?BAQEBAQEBBwEBAQEBAYFlgQ5NKWaBAicKg3eTfIINiSKQVwsBASMJhEACF4J?= =?us-ascii?q?BIjgSAQMBAQIBAQJtHAyFSgEBAQEDIwpMEAIBCBEDAQIhAQkCAgIfER0IAgQ?= =?us-ascii?q?OBYJXSwGBHUwDFQ+rboEviAoNghgFjD8XgUA/gTgfgU5+gldHAQECAYEzAUE?= =?us-ascii?q?JgmkxggQiAok8IS+FXRmGVIpgJzMJAocghzqDNxiBZYUqglmII4sIhBCBFYo?= =?us-ascii?q?6AhEUgSc2IYFWcBU7KgGCQYIkGoEAAQyHUoU/cgGBJ4hsAYEeAQE?=
X-IronPort-AV: E=Sophos;i="5.56,489,1539648000"; d="scan'208,217";a="227011799"
Received: from ([]) by with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 17 Jan 2019 16:15:49 +0000
Received: from ( []) by (8.15.2/8.15.2) with ESMTPS id x0HGFmbW007841 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=FAIL); Thu, 17 Jan 2019 16:15:49 GMT
Received: from ( by ( with Microsoft SMTP Server (TLS) id 15.0.1395.4; Thu, 17 Jan 2019 11:15:47 -0500
Received: from ([]) by ([]) with mapi id 15.00.1395.000; Thu, 17 Jan 2019 11:15:47 -0500
From: "Tarek Saad (tsaad)" <>
To: Jan Lindblad <>
CC: "" <>, "" <>, "" <>, "" <>
Thread-Topic: Yangdoctors early review of draft-ietf-teas-yang-te-types-01
Thread-Index: AQHUcFhpW4TIV6pgnUO+yleCnV98uaU9iq4AgAO524CActqVgA==
Date: Thu, 17 Jan 2019 16:15:47 +0000
Message-ID: <>
References: <> <> <>
In-Reply-To: <>
Accept-Language: en-US
Content-Language: en-US
user-agent: Microsoft-MacOutlook/
x-ms-exchange-messagesentrepresentingtype: 1
x-ms-exchange-transport-fromentityheader: Hosted
x-originating-ip: []
Content-Type: multipart/alternative; boundary="_000_BB36593B0A4E4F88A0883C35BBCAB902ciscocom_"
MIME-Version: 1.0
Archived-At: <>
Subject: Re: [Teas] Yangdoctors early review of draft-ietf-teas-yang-te-types-01
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Traffic Engineering Architecture and Signaling working group discussion list <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Thu, 17 Jan 2019 16:15:55 -0000

Hi Jan

Thanks again for your thorough review and comments. We have uploaded version -03 of the draft that addresses your comments. Please see Inline [TS] for the resolution action taken.
Please let us know if you have any further comments.

From: Jan Lindblad <>
Date: Monday, November 5, 2018 at 4:20 AM
To: Tarek Saad <>
Cc: "" <>rg>, "" <>rg>, "" <>rg>, "" <>
Subject: Re: Yangdoctors early review of draft-ietf-teas-yang-te-types-01
Resent-From: <>
Resent-To: Tarek Saad <>om>, <>om>, <>om>, <>et>, <>om>, <>et>, <>om>, <>om>, <>om>, <>om>, Lou Berger <>
Resent-Date: Monday, November 5, 2018 at 4:19 AM


See my comments below [janl].

    General questions:

    #1: There are many locations in the YANG talking about an "ERO subobject index"
    (and once RRO index, record route subobject). What is this, and how is it
    supposed to be used? The document is silent on this matter, and I have seen
    modules with problems around numeric index leafs much like this earlier. Are
    these numbers stable, i.e. remains the same forever?

[TS]: The list of explicit route objects defines a TE path (e.g. hops), where the index is used as a key to identify a specific entry in the list. A lower index implies the TE path traverses this entry earlier. We will clarify the description and remove mention of “subobject” in the next update to the document.

[janl] Very good re description changes.

I'm a little worried that numeric indices will end up in the same quagmire+impasse where ACLs have been the last decades. Isn't there a risk that people will want to insert entries between two consecutive indices? Is "renumber" an operation that someone might ask for on these indices?
[TS]: The list is ordered by the key (index).. We’ve added a note in the description that entries with lower index are visited first by the path. It is understandable that the list may have to be reconfigured if an entry can not be fit in between two existing ones. Note, a change in the configured ERO list is generally handled as non-destructive event to an existing/provisioned tunnel (e.g. handled as make-before-break).

      leaf index {
        type uint32;
          "Route object entry index. A lower index indicates
           path traverses the hop earlier than the higher index

    #2: There are few leafs (5) with default values given, and none with mandatory.
    Probably needs to increase before we get to last call.
[TS]: In general, the team tried to avoid setting defaults unless it is strictly dictated by another RFC/standard. The team will review again to see if any was missed and will take action.

[janl] That's all fine. Just remember to describe what happens when a leaf has no value every time there is no default or mandatory. Easy to forget, experience shows. Missing this causes non-interoperability in the standard.
[TS]: the team has opted to assign defaults to all optional leafs in the latest revision of the draft.

    #3: There are several choices in the module that are meant to be augmented with
    additional cases. In many instances, this is explicitly spelled out, very good.
    If this is meant to happen in all choices, it would be nice to point this out
    in every instance. Also, if there are any specific assumptions or
    considerations to keep in mind when augmenting in a new technology, please note
    that in the description as well.
[TS]: yes, we will update as necessary.

[janl] Great!

    Issues and nits:

    #4: Unclear data type
      typedef admin-group {
        type binary {
          length 4;

    What is the format of this binary? If this is always a 4-byte binary, wouldn't
    a numeric type be more user friendly, e.g. uint32?
[TS]: the standard defines admin group as 4-octet binary (9 - Administrative group (4 octets) ), and for extended-admin-group as series of those. We are also defining a union to encompass both as admin-groups below. Do you still have concerns on this?

  typedef admin-groups {
    type union {
      type admin-group;
      type extended-admin-group;
    description "TE administrative group derived type";

[janl] I'm have two concerns. The first is that I don't know what the format of the type is. How do I know how to construct one of these values, or interpret an existing one? Is this a randomly chosen value? The other concern is how an operator would enter this value. The binary type is not the most user friendly of types. A numeric representation in the management interface might make better sense.
[TS]: RFC3630 and RFC5305 defines admin-groups (aka affinity colors) as binary flags that are user specified (e.g. bit-position X is for RED, and bit-position Y is for GREEN). So, binary type would be closest to this representation. On other hand, RFC7591 states that a binary value is represented as a JSON string -- base64 encoding ( Let us know if there are still concerns on this.

    #5: identifier in container with optional leafs
      grouping te-topology-identifier {

    The name suggests this is used as an identifier, but all the leafs are
    optional. This is not typical. They are also in a container, precluding them
    from being used as list keys. Is that as intended?
[TS]: this container is not meant to be reused for a list, rather contains ID(s) that together can be used to lookup a specific topology that the TE tunnel is using. We can clarify this in the description

[janl] Hmm, ok. Still not sure what happens if you omit some value(s), but I guess I should wait to see your clarification.
[TS]: we have addressed this by specifying defaults for the optional leafs.

    #6: Optional -id leafs again
              leaf node-id {
              leaf link-tp-id {
            leaf address {
            leaf node-id {
            leaf link-tp-id {

    Leafs that appear to be used as identifiers are optional
[TS]: such IDs identify a specific node, link, or address in the network but in our applications we do not to use them as keys in such lists. For example list explicit-route-objects defines a separate index leaf to be used as key -- since, a path may contain the same node-id or address repeated multiple times (looping path)..

[janl] So what happens if you omit specifying some of them?
[TS]: This was reworked and added a mandatory to leafs that are must, and added defaults to optional leafs.

    #7: binary length in bits?
               leaf as-number {
                type binary {
                  length 16;
            leaf ip-flags {
              type binary {
                length 8;
              leaf label-flags {
                type binary {
                  length 8;

    It appears to me the modeler might have thought the length is given in bits.
    The value of length is in bytes, however.
[TS]: good catch, thanks. We'll correct it to indicate number of octets as RFC6020 defines.

    #8: Must expression copy paste
        container label-end {
          must "not(../label-end/te-label/direction) or "
            + "not(te-label/direction) "
            + "or ../label-end/te-label/direction = te-label/direction" {

    This must expression appears to have been copied from label-start. In any case,
    it always evaluates to true and has no effect.
[TS]: thanks, we can see the bug in the expression as is, and this will be fixed/updated.

        container label-end {
          must "not(../label-start/te-label/direction) or "
            + "not(te-label/direction) "
            + "or ../label-start/te-label/direction = te-label/direction" {

[janl] This revised must statement is superfluous. The must statement on container label-start already covers this case.
[TS]: addressed

    #9: Unclear bit field
        leaf range-bitmap {
          type binary;
            "When there are gaps between label-start and label-end,
             this attribute is used to specify the positions
             of the used labels.";

    Need more information on how to interpret this leaf. Which bits map to what,
    and what does the bit field values 0 and 1 indicate?
[TS]: ]: Each bit-position in the bitmap will map to an offset from the label-start. For example, if label-start=16000 and bitmap=0x11, then labels={16000, 16004} are relevant. We will clarify this in the next update.

[janl] Very good. Since you are using type binary and refer to the contents using integers, you should also specify how you map those integer values to bit positions in the binary. E.g. big-endian?
[TS]: We have clarified this in the description of the leaf that it is big-endian representation

    #10: Canonical representation
      typedef te-bandwidth {

    The type is based on a string with a pattern allowing hex characters and an
    upper or lowercase P. Since the pattern allows multiple representations of the
    same underlaying value (0x1p10 presumably means the same as 0x1p0xa and
    0x1P0XA) the question comes up if there is a canonical representation of this
    value, e.g. using all lowercase and all hex, or if the string must be
    remembered exactly as given by the client. The description could answer this
[TS]: We will update the description to indicate more strict canonical form (all upper case).

    #11: Mix of upper and lowercase
    The module specifies many enumeration and identity values. Some are all
    lowercase. Some are all uppercase. The principle of least astonishment suggests
    to pick one and stick with it. YANG recommendations suggest to use all
    lowercase when in doubt.

      typedef te-link-direction {
      typedef te-label-direction {
      typedef te-hop-type {
      identity LSP_METRIC_TYPE {
      identity LSP_METRIC_RELATIVE {
      identity LSP_METRIC_ABSOLUTE {
      identity LSP_METRIC_INHERITED {
[TS]: we will update to all lower-case to align with YANG recommendations.

[janl] Great!