Re: [netmod] proposal to add 2 new guidelines in 6087bis

Robert Wilton <rwilton@cisco.com> Mon, 30 January 2017 11:38 UTC

Return-Path: <rwilton@cisco.com>
X-Original-To: netmod@ietfa.amsl.com
Delivered-To: netmod@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8311F12945A for <netmod@ietfa.amsl.com>; Mon, 30 Jan 2017 03:38:29 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -17.719
X-Spam-Level:
X-Spam-Status: No, score=-17.719 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-3.199, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=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 YUZ9g5r6ES3R for <netmod@ietfa.amsl.com>; Mon, 30 Jan 2017 03:38:28 -0800 (PST)
Received: from aer-iport-4.cisco.com (aer-iport-4.cisco.com [173.38.203.54]) (using TLSv1.2 with cipher DHE-RSA-SEED-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 5E649129454 for <netmod@ietf.org>; Mon, 30 Jan 2017 03:38:27 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=11005; q=dns/txt; s=iport; t=1485776307; x=1486985907; h=subject:to:references:cc:from:message-id:date: mime-version:in-reply-to; bh=ssMVLx4+9ZDdVM0S4V8IKAPIDBr2AFuDqcMW1WchQmk=; b=OHrtxea3cxRDpUKPTY0Cr8taJ6gSry2T8jXEnhGuxM+ztv37JSsow28W 8fo58JgiXd5holSC3pyw9m7rClja6n7vJOQaseGbRkWpeTkLxZY4pmWO3 jQ/6jKz7JVxR35pQenFIbQOioPzOe/wbnoP/IjoK6DBacDYFVik7i90qb o=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: A0DhAQD9JI9Y/xbLJq1dGQEBAQEBAQEBAQEBBwEBAQEBhDQqX41ecpBwH5AHhSuCDB8BCoUuSgKCTxgBAgEBAQEBAQFiKIRpAQEBAwEBAWwLBQsLGCcHJx8RBgEMBgIBAYlYCA6tNCuKRQEBAQEBAQEBAQEBAQEBAQEBAQEBARgFhkuCBQiCYoouBZtUigGHeoF5iD8jhhyLAId/HziBGxMIFRU7hASCNUA1hXgrgg8BAQE
X-IronPort-AV: E=Sophos;i="5.33,311,1477958400"; d="scan'208,217";a="652083032"
Received: from aer-iport-nat.cisco.com (HELO aer-core-3.cisco.com) ([173.38.203.22]) by aer-iport-4.cisco.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 30 Jan 2017 11:38:25 +0000
Received: from [10.63.23.109] (dhcp-ensft1-uk-vla370-10-63-23-109.cisco.com [10.63.23.109]) by aer-core-3.cisco.com (8.14.5/8.14.5) with ESMTP id v0UBcOJb013146; Mon, 30 Jan 2017 11:38:25 GMT
To: Andy Bierman <andy@yumaworks.com>, Ladislav Lhotka <lhotka@nic.cz>
References: <CABCOCHSXk9oxoD-bPsUnSurrGxo2N3Gbu5KP2vpLigCF6ZmD0A@mail.gmail.com> <A59FD2B2-D017-4BA8-BC69-89041794C853@nic.cz> <CABCOCHTbS0P_iTwC7ngPRhNhFwxMg-H9ALf8xy126xdZp7zJtg@mail.gmail.com>
From: Robert Wilton <rwilton@cisco.com>
Message-ID: <449fb3a4-fbf5-bfa6-7530-fdfc7fe0488b@cisco.com>
Date: Mon, 30 Jan 2017 11:38:24 +0000
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0
MIME-Version: 1.0
In-Reply-To: <CABCOCHTbS0P_iTwC7ngPRhNhFwxMg-H9ALf8xy126xdZp7zJtg@mail.gmail.com>
Content-Type: multipart/alternative; boundary="------------A95DB2EEE09F4A2B784070B2"
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/A9wl5z6ZR215BSAbMF5cLeeiM2c>
Cc: "netmod@ietf.org" <netmod@ietf.org>
Subject: Re: [netmod] proposal to add 2 new guidelines in 6087bis
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: NETMOD WG list <netmod.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netmod>, <mailto:netmod-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netmod/>
List-Post: <mailto:netmod@ietf.org>
List-Help: <mailto:netmod-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netmod>, <mailto:netmod-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 30 Jan 2017 11:38:29 -0000

Hi Andy, Lada,


On 28/01/2017 16:23, Andy Bierman wrote:
>
>
> On Sat, Jan 28, 2017 at 2:54 AM, Ladislav Lhotka <lhotka@nic.cz 
> <mailto:lhotka@nic.cz>> wrote:
>
>
>     > On 27 Jan 2017, at 20:23, Andy Bierman <andy@yumaworks.com
>     <mailto:andy@yumaworks.com>> wrote:
>     >
>     > Hi,
>     >
>     > The "pyang --ietf" validator checks the statement order used in
>     data-def-stmts.
>     > There is no guideline that says this is required.
>     > RFC 7950 says canonical order is RECOMMENDED.
>     >
>     > 1) data-def sub-statement order
>     > Proposal: add new last sentence to sec. 4.6, para 3:
>     >
>     > YANG data definition sub-statements SHOULD be specified in
>     canonical order.
>
>     IMO, this adds nothing to what's already stated in 7950. According
>     to RFC 2119, SHOULD and RECOMMENDED mean the same.
>
I support Andy's recommendation here, although I think that it might 
also be useful to cross reference back to where the canonical order is 
actually defined in 7950.

Lada, you are right that 7950 recommends the correct ordering, but I 
think that it is buried with the ABNF, which won't necessarily be read 
by all users of YANG.  Pulling it out in 6087bis doesn't seem to do any 
harm.


>
>
>
> OK
>
>     >
>     >
>     > 2) enum/bit statement ordering
>     >
>     > Proposal: add new para 2 to  sec 5.11.3:
>     >
>     > The 'enum' statements within an 'enumeration' data type SHOULD be
>     > specified in ascending order, based on the implied and/or
>     explicit values
>     > of the 'value' sub-statement. The 'bit' statements within a
>     'bits' data type
>     > SHOULD be specified in ascending order, based on the implied and/or
>     > explicit values of the 'position' sub-statement.
>
>     I don't agree. For some enumerations, especially those with a
>     large number of enums, it is much more useful for the reader to
>     have the enums ordered differently, e.g. alphabetically or
>     geographically. On the other hand, numeric enum values often need
>     to be assigned in the order how enums are defined in subsequent
>     revisions.
>
>
>
> We have been using ascending order in MIB modules and YANG modules
> all along.  I think there are about 5000 modules in ascending order 
> and one not
> in ascending order.  The guideline is SHOULD anyway.
+1.  Isn't this exactly what a SHOULD statement means.  I.e. put in 
ascending order unless there is a good reason not to do so (e.g. as per 
Lada's examples), in which case that is fine.

Rob


>
> YANG prohibits the value or position numbers from changing in
> a new revision, so preserving previous ordering is required.
>
>     Lada
>
>
> Andy
>
>
>     >
>     >
>     >
>     > Andy
>     >
>     > _______________________________________________
>     > netmod mailing list
>     > netmod@ietf.org <mailto:netmod@ietf.org>
>     > https://www.ietf.org/mailman/listinfo/netmod
>     <https://www.ietf.org/mailman/listinfo/netmod>
>
>     --
>     Ladislav Lhotka, CZ.NIC Labs
>     PGP Key ID: 0xB8F92B08A9F76C67
>
>
>
>
>
>
>
>
> _______________________________________________
> netmod mailing list
> netmod@ietf.org
> https://www.ietf.org/mailman/listinfo/netmod