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

"Tarek Saad (tsaad)" <tsaad@cisco.com> Sat, 03 November 2018 05:27 UTC

Return-Path: <tsaad@cisco.com>
X-Original-To: ietf@ietfa.amsl.com
Delivered-To: ietf@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id B58AB12D4EB; Fri, 2 Nov 2018 22:27:42 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -14.97
X-Spam-Level:
X-Spam-Status: No, score=-14.97 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.47, 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: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=cisco.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0x8se3WeGDe2; Fri, 2 Nov 2018 22:27:39 -0700 (PDT)
Received: from rcdn-iport-9.cisco.com (rcdn-iport-9.cisco.com [173.37.86.80]) (using TLSv1.2 with cipher DHE-RSA-SEED-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 82C2B127133; Fri, 2 Nov 2018 22:27:38 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=68502; q=dns/txt; s=iport; t=1541222858; x=1542432458; h=from:to:cc:subject:date:message-id:references: in-reply-to:mime-version; bh=cMh43sS16HNqc4PswkW960DPmxFGU3AE+UIHcwU2INw=; b=P9ZMhykGM8Or4p4USugc92nHlYytFxCfP1nXF2vKJWcYSVGstg+iZe0A ny576cpUd9OmuJEJ0bBQ2DWu+G+52t3wlCqpyQUcwwtmvitRASZ/4HB1M K95qDiBn202FfCf1jwJ9EmqTCWMxCk5bx5sosjljIDYZPKqmmP9wtQ9TO M=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: A0BCAABbMd1b/4UNJK1YAQkZAQEBAQEBAQEBAQEBBwEBAQEBAYFlgQ53Zn8oCoNslhYliQKQJAsBAYRsAheDJyI4FgEDAQECAQECbSiFOgEBAQQjVgwEAgEIEQMBAiEBBgMCAgIfERQJCAIEAQ0FgyEBgR1MAxWneIEuh3oNghiLcReBQT+BOAwTgkyCVoF9AUEJgmQxggQiAohkToUrFoYUiVImLgkCjWKDKhiBVYR/igqJQIRIiRACERSBJjQhgVVwFTsqAYJBgiQajhpvAYxSgR8BAQ
X-IronPort-AV: E=Sophos;i="5.54,458,1534809600"; d="scan'208,217";a="390430176"
Received: from alln-core-11.cisco.com ([173.36.13.133]) by rcdn-iport-9.cisco.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 03 Nov 2018 05:27:36 +0000
Received: from XCH-RTP-005.cisco.com (xch-rtp-005.cisco.com [64.101.220.145]) by alln-core-11.cisco.com (8.15.2/8.15.2) with ESMTPS id wA35Raoc028896 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=FAIL); Sat, 3 Nov 2018 05:27:36 GMT
Received: from xch-rtp-001.cisco.com (64.101.220.141) by XCH-RTP-005.cisco.com (64.101.220.145) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Sat, 3 Nov 2018 01:27:35 -0400
Received: from xch-rtp-001.cisco.com ([64.101.220.141]) by XCH-RTP-001.cisco.com ([64.101.220.141]) with mapi id 15.00.1395.000; Sat, 3 Nov 2018 01:27:35 -0400
From: "Tarek Saad (tsaad)" <tsaad@cisco.com>
To: Jan Lindblad <janl@tail-f.com>, "yang-doctors@ietf.org" <yang-doctors@ietf.org>
CC: "draft-ietf-teas-yang-te-types.all@ietf.org" <draft-ietf-teas-yang-te-types.all@ietf.org>, "ietf@ietf.org" <ietf@ietf.org>, "teas@ietf.org" <teas@ietf.org>
Subject: Re: Yangdoctors early review of draft-ietf-teas-yang-te-types-01
Thread-Topic: Yangdoctors early review of draft-ietf-teas-yang-te-types-01
Thread-Index: AQHUcFhpW4TIV6pgnUO+yleCnV98uaU9iq4A
Date: Sat, 03 Nov 2018 05:27:35 +0000
Message-ID: <973699DE-882E-4531-A7D5-32AFEF4359E7@cisco.com>
References: <154090780735.15255.3911131220920609603@ietfa.amsl.com>
In-Reply-To: <154090780735.15255.3911131220920609603@ietfa.amsl.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/10.10.2.180910
x-ms-exchange-messagesentrepresentingtype: 1
x-ms-exchange-transport-fromentityheader: Hosted
x-originating-ip: [10.86.242.151]
Content-Type: multipart/alternative; boundary="_000_973699DE882E4531A7D532AFEF4359E7ciscocom_"
MIME-Version: 1.0
X-Outbound-SMTP-Client: 64.101.220.145, xch-rtp-005.cisco.com
X-Outbound-Node: alln-core-11.cisco.com
Archived-At: <https://mailarchive.ietf.org/arch/msg/ietf/Ip5PW7XDPpPsqM91am5nOR1LKNU>
X-BeenThere: ietf@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: IETF-Discussion <ietf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ietf>, <mailto:ietf-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ietf/>
List-Post: <mailto:ietf@ietf.org>
List-Help: <mailto:ietf-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ietf>, <mailto:ietf-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Nov 2018 05:27:43 -0000

Hi Jan,



Thanks much for the thorough review and comments. Please see inline for responses and intended closure. Let us know if you have further comments/concerns.


-----Original Message-----
From: Jan Lindblad <janl@tail-f.com<mailto:janl@tail-f.com>>
Date: Tuesday, October 30, 2018 at 8:56 PM
To: "yang-doctors@ietf.org<mailto:yang-doctors@ietf.org>" <yang-doctors@ietf.org<mailto:yang-doctors@ietf.org>>
Cc: "draft-ietf-teas-yang-te-types.all@ietf.org<mailto:draft-ietf-teas-yang-te-types.all@ietf.org>" <draft-ietf-teas-yang-te-types.all@ietf.org<mailto:draft-ietf-teas-yang-te-types.all@ietf.org>>, "ietf@ietf.org<mailto:ietf@ietf.org>" <ietf@ietf.org<mailto:ietf@ietf.org>>, "teas@ietf.org<mailto:teas@ietf.org>" <teas@ietf.org<mailto:teas@ietf.org>>
Subject: Yangdoctors early review of draft-ietf-teas-yang-te-types-01
Resent-From: <alias-bounces@ietf.org<mailto:alias-bounces@ietf.org>>
Resent-To: Tarek Saad <tsaad@cisco.com<mailto:tsaad@cisco.com>>, <rgandhi@cisco.com<mailto:rgandhi@cisco.com>>, <xufeng.liu.ietf@gmail.com<mailto:xufeng.liu.ietf@gmail.com>>, <vbeeram@juniper.net<mailto:vbeeram@juniper.net>>, <igor.bryskin@huawei.com<mailto:igor.bryskin@huawei.com>>, <lberger@labn.net<mailto:lberger@labn.net>>, <mhartley.ietf@gmail.com<mailto:mhartley.ietf@gmail.com>>, <martin.vigoureux@nokia.com<mailto:martin.vigoureux@nokia.com>>, <db3546@att.com<mailto:db3546@att.com>>, <aretana.ietf@gmail.com<mailto:aretana.ietf@gmail.com>>, Lou Berger <lberger@labn.net<mailto:lberger@labn.net>>
Resent-Date: Tuesday, October 30, 2018 at 8:56 PM


    Reviewer: Jan Lindblad
    Review result: Ready with Issues

    This is my YANG Doctor early review of draft-ietf-teas-yang-te-types, or more
    specifically ietf-te-types.yang . I find the module ready with a couple of
    issues. I have also noted a few nits. Generally speaking, I'm not sure if
    reviewing a -types module with plenty of groupings on its own is the best way
    to go about it. The groupings defined here may be used in good or not so good
    ways later.

    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.

    #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.

    #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.


    Issues and nits:

    #4: Unclear data type
    419:
      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";
  }

    #5: identifier in container with optional leafs
    1496:
      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


    #6: Optional -id leafs again
    1700:
              leaf node-id {
              leaf link-tp-id {
    1768:
            leaf address {
    1783:
            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)..

    #7: binary length in bits?
    1731:
               leaf as-number {
                type binary {
                  length 16;
    1773:
            leaf ip-flags {
              type binary {
                length 8;
    1805:
              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
    1852:
        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" {


    #9: Unclear bit field
    1885:
        leaf range-bitmap {
          type binary;
          description
            "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.

    #10: Canonical representation
    67:
      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
    question.
[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.

    Best Regards,
    /jan


Regards,

Tarek