Re: [netmod] Regarding origin annotation encoding in ietf-netconf-nmda-restconf-05

Robert Wilton <rwilton@cisco.com> Thu, 14 February 2019 11:26 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 647EB131160 for <netmod@ietfa.amsl.com>; Thu, 14 Feb 2019 03:26:40 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -14.5
X-Spam-Level:
X-Spam-Status: No, score=-14.5 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, 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, 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 2eS91jXPSVAO for <netmod@ietfa.amsl.com>; Thu, 14 Feb 2019 03:26:38 -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 4A27E131055 for <netmod@ietf.org>; Thu, 14 Feb 2019 03:26:38 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=6197; q=dns/txt; s=iport; t=1550143598; x=1551353198; h=subject:to:references:from:message-id:date:mime-version: in-reply-to; bh=CbjOAf4HXVb5lZpS4RdxNVotXd7lt5lyZK5tYo5lxE8=; b=f5gal7yr8E5OUT8e2pa1Sp3UQIGFEl9Q2AdpZ5dBm00mXdshl2R6Y2Th ZE1FrYo3yjn3xjLPsSQU/Lc517F88SFpED7Jjk/1H9WiX8aJvf2SmrmaJ mV4fHWY2ExFGUGvtT245B/FW1I9O3FUQ+vw8denI9+VXY7N65pmQMLAeT 8=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: A0AKAACnT2Vc/xbLJq0YAUoaAQEBAQECAQEBAQcCAQEBAYFTAwEBAQELAQGCaHESJ4QGiHmNH5IkhW+Bew0YAQqEA0YChAI2Bw0BAwEBAgEBAm0cDIVLAQEEAQEhSxsJAg4KKgICJzAGAQwGAgEBgxwBgXIPi0mCIZthgS8fhSWEcAWMW4FAP4E4gmuDHgEBhGqCVwKQQJJuCZJOBhmKWogZh1KCaIpxhyeBTQQtgVYzGggbFTuCbIJSiEyFPz8DMI8yAQE
X-IronPort-AV: E=Sophos; i="5.58,368,1544486400"; d="scan'208,217"; a="10030140"
Received: from aer-iport-nat.cisco.com (HELO aer-core-4.cisco.com) ([173.38.203.22]) by aer-iport-4.cisco.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Feb 2019 11:26:36 +0000
Received: from [10.63.23.84] (dhcp-ensft1-uk-vla370-10-63-23-84.cisco.com [10.63.23.84]) by aer-core-4.cisco.com (8.15.2/8.15.2) with ESMTP id x1EBQZRc004951; Thu, 14 Feb 2019 11:26:35 GMT
To: Amar Jadagoud <ammys.vas@gmail.com>, netmod@ietf.org
References: <CAKiLt9+K=X2jRWJZo4vT4DC=aNVH0RL6b2ByNwh2Z1JykcWcPw@mail.gmail.com>
From: Robert Wilton <rwilton@cisco.com>
Message-ID: <d8bc9eae-c947-4f13-b22c-ee2207ec6b99@cisco.com>
Date: Thu, 14 Feb 2019 11:26:35 +0000
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0
MIME-Version: 1.0
In-Reply-To: <CAKiLt9+K=X2jRWJZo4vT4DC=aNVH0RL6b2ByNwh2Z1JykcWcPw@mail.gmail.com>
Content-Type: multipart/alternative; boundary="------------0845B1AD9659C1BC114FAE36"
Content-Language: en-US
X-Outbound-SMTP-Client: 10.63.23.84, dhcp-ensft1-uk-vla370-10-63-23-84.cisco.com
X-Outbound-Node: aer-core-4.cisco.com
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/xsCBGsIPNVnzEHEuWHZUzIVUo60>
Subject: Re: [netmod] Regarding origin annotation encoding in ietf-netconf-nmda-restconf-05
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, 14 Feb 2019 11:26:40 -0000

Hi Amar,

Based on RFC 7952 section 5.2.1, I think that it would look like this:

{
     "example:interface" : [
        {
            "name" : "eth1",
            "mtu" : 1500,
            "@mtu" : {
                   "ietf-netconf-with-defaults:default" : true,
   "ietf-origin:origin" : intended
               },
            "status" : "up"
       }
   ]
}

Thanks,
Rob


On 14/02/2019 06:49, Amar Jadagoud wrote:
> Hi All,
>
> I have a question regarding encoding of origin annotation along with 
> other annotation (with-defaults) in JSON metadata encoding format.
>
> Suppose if below is the GET method :
>
> GET 
> /restconf/ds/ietf-datastores:operational/ietf-interface:interfaces/interface=eth1?with-defaults=report-all-tagged&with-origin 
> HTTP/1.1
>
> How both origin and with-defaults annotations should be encoded in the 
> JSON metadata encoding format?
>
> Currently in restconf RFC 8040, in section 5.3.2, example with only 
> one annotation is provided.
>
>  Refering to this example, whether multiple annotation representation 
> should be like below?
>
> {
>     "example:interface" : [
>        {
>            "name" : "eth1",
>            "mtu" : 1500,
>            "@mtu" : {
> "ietf-netconf-with-defaults:default" : true
>               },
>               {
>                     "ietf-origin:origin" : intended
>               },
>               "status" : "up"
>       }
>   ]
> }
>
> Thanks,
> Amar
>
> _______________________________________________
> netmod mailing list
> netmod@ietf.org
> https://www.ietf.org/mailman/listinfo/netmod