Re: [netmod] RFC 8342 : Query about NMDA Origin for Non-presence containers

Rohit R Ranade <rohitrranade@huawei.com> Thu, 27 September 2018 11:17 UTC

Return-Path: <rohitrranade@huawei.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 1117B130E45 for <netmod@ietfa.amsl.com>; Thu, 27 Sep 2018 04:17:31 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.9
X-Spam-Level:
X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
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 k0uefe1hs6dv for <netmod@ietfa.amsl.com>; Thu, 27 Sep 2018 04:17:28 -0700 (PDT)
Received: from huawei.com (lhrrgout.huawei.com [185.176.76.210]) (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 A4B92130E37 for <netmod@ietf.org>; Thu, 27 Sep 2018 04:17:28 -0700 (PDT)
Received: from LHREML710-CAH.china.huawei.com (unknown [172.18.7.108]) by Forcepoint Email with ESMTP id F092BE9431C22; Thu, 27 Sep 2018 12:17:24 +0100 (IST)
Received: from DGGEML406-HUB.china.huawei.com (10.3.17.50) by LHREML710-CAH.china.huawei.com (10.201.108.33) with Microsoft SMTP Server (TLS) id 14.3.399.0; Thu, 27 Sep 2018 12:17:25 +0100
Received: from DGGEML510-MBX.china.huawei.com ([169.254.2.22]) by dggeml406-hub.china.huawei.com ([10.3.17.50]) with mapi id 14.03.0382.000; Thu, 27 Sep 2018 19:17:17 +0800
From: Rohit R Ranade <rohitrranade@huawei.com>
To: Robert Wilton <rwilton@cisco.com>, Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>
CC: "netmod@ietf.org" <netmod@ietf.org>
Thread-Topic: [netmod] RFC 8342 : Query about NMDA Origin for Non-presence containers
Thread-Index: AdRWPLcxKIuEiDOcQMSB/ApCgMB4/f//fyUA//9159CAAJoWAP//YfxA
Date: Thu, 27 Sep 2018 11:17:16 +0000
Message-ID: <991B70D8B4112A4699D5C00DDBBF878A6BC4D470@dggeml510-mbx.china.huawei.com>
References: <991B70D8B4112A4699D5C00DDBBF878A6BC4CAFF@dggeml510-mbx.china.huawei.com> <20180927085156.vhfp6pcvpm35r6fb@anna.jacobs.jacobs-university.de> <991B70D8B4112A4699D5C00DDBBF878A6BC4D37B@dggeml510-mbx.china.huawei.com> <284d7c28-5112-5a12-abcd-e2ab824924c9@cisco.com>
In-Reply-To: <284d7c28-5112-5a12-abcd-e2ab824924c9@cisco.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [10.18.150.121]
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-CFilter-Loop: Reflected
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/LejKzqeFx8ly1uymm20gOceczl8>
Subject: Re: [netmod] RFC 8342 : Query about NMDA Origin for Non-presence containers
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.29
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: Thu, 27 Sep 2018 11:17:31 -0000

Instead of choosing the origin for non-presence container as "unknown" or any other origin, I would prefer if the rule in annotation definition " The origin for any top-level configuration data nodes must be specified." can be relaxed.

With Regards,
Rohit R Ranade


-----Original Message-----
From: Robert Wilton [mailto:rwilton@cisco.com] 
Sent: 27 September 2018 15:19
To: Rohit R Ranade <rohitrranade@huawei.com>; Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>
Cc: netmod@ietf.org
Subject: Re: [netmod] RFC 8342 : Query about NMDA Origin for Non-presence containers

Hi Rohit,

Please see inline ...


On 27/09/2018 10:11, Rohit R Ranade wrote:
> Please find inline.
>
> Rohit R Ranade
>
>
> -----Original Message-----
> From: Juergen Schoenwaelder 
> [mailto:j.schoenwaelder@jacobs-university.de]
> Sent: 27 September 2018 14:22
> To: Rohit R Ranade <rohitrranade@huawei.com>
> Cc: netmod@ietf.org
> Subject: Re: [netmod] RFC 8342 : Query about NMDA Origin for 
> Non-presence containers
>
> On Thu, Sep 27, 2018 at 08:40:10AM +0000, Rohit R Ranade wrote:
>> Hi All,
>>
>> Section 5.3.4:
>> "The
>>     origin applies to all configuration nodes except non-presence
>>     containers.  "
>>
>> In ietf-origin YANG module:
>>       md:annotation origin {
>>         type origin-ref;
>>         description
>>           "The 'origin' annotation can be present on any configuration
>>            data node in the operational state datastore.  It specifies
>>            from where the node originated.  If not specified for a given
>>            configuration data node, then the origin is the same as the
>>            origin of its parent node in the data tree.  The origin for
>>            any top-level configuration data nodes must be specified.";
>>       }
>>
>>
>> C.1.  System Example:
>> The root node "system", is config-true and a non-presence container, 
>> and in the example, does not have the  "origin" meta-data attribute
>>
>>
>> Keeping all the above points in mind, which is the correct way ? Whether the top-level configuration node should contain the "origin" attribute for Non-presence containers ?
>>
> Let me first clarify the difference between 'a node carrying an origin annotation' and 'an origin annotation applying to a node':
>
> - Any node can 'carry an origin annotation' (but it may not apply to
>    the node). If a node does not 'carry an origin annotation', then the
>    parent node is inspected whether it carries an origin annotation.
>
> - An origin annotation applys to a node if it is a node to which an
>    origin annotation can be applied. Since non-presence containers have
>    meaning by themself, the origin annotation does not apply to
>    non-presence containers (but they may still 'carry an origin
>    annotation'.
>
> Given the requirement stated in the definition md:annotation origin, 
> it seems that the "system" top-level container should have an origin 
> annotation. (One can debate whether this requirement is too strict 
> since in the example an origin annotation of the "system" top-level 
> container would not apply to anything since all the nodes below 
> "system" have explicit origin annotations.)
Give the two statements above from Juergen then for a top level np container, the server may return any origin value that it wishes, as long as the correct origin is returned (either implicitly or explicitly) for all descendant nodes that are not np-containers.

One choice would to always set all top level np containers to origin "unknown".

An alternative choice is, if there are no configured (with presence) children then set it to "default", but as soon as there is at least one configured (with presence) child set it to "intended".

The specification allows any value, and neither choice impart any additional useful information to the client, so choose whichever is most convenient to implement ...

Thanks,
Rob


> [Rohit R Ranade] So how to decide the origin annotation for top-level non-presence container. Consider the case of "nacm" root node of ietf-netconf-acm module which is a container.
> Consider that "enable-nacm" came via "intended" origin, and "read-default" came via "default" origin.
>        +--rw nacm
>           +--rw enable-nacm?            boolean
>           +--rw read-default?           action-type
>           +--rw write-default?          action-type
>           +--rw exec-default?           action-type
> [Rohit R Ranade] So how to decide the origin for the container, when its child may have mixed origin ?
> /js
>