[yang-doctors] Clarification on YANG Schema Node Identifiers (wrt RPCs)

Abhinava Shivakumar Sadasivarao <ASadasivarao@infinera.com> Tue, 28 August 2018 04:04 UTC

Return-Path: <ASadasivarao@infinera.com>
X-Original-To: yang-doctors@ietfa.amsl.com
Delivered-To: yang-doctors@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 22514130E32 for <yang-doctors@ietfa.amsl.com>; Mon, 27 Aug 2018 21:04:05 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.999
X-Spam-Level:
X-Spam-Status: No, score=-1.999 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_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=infinera.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 HqvSiSQqH_EH for <yang-doctors@ietfa.amsl.com>; Mon, 27 Aug 2018 21:04:02 -0700 (PDT)
Received: from NAM03-BY2-obe.outbound.protection.outlook.com (mail-by2nam03on0078.outbound.protection.outlook.com [104.47.42.78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 8A85512008A for <yang-doctors@ietf.org>; Mon, 27 Aug 2018 21:04:02 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=infinera.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=a1PEOLIWAS6gL6eC36UEOkru4PXDpiqddvOUGZWC9iI=; b=OUJqrRO3AfzfCd5QPB6ttCJVAaOQS017yHEzde2tJtUqHMS2RICW1wmCsm+6Vpj0GRkgce3jnqU5YZQZHYS05GvtaAVmkmpHbdzXYACfykQ0Hkrbq4xU2e/1gFnvVxyGOJ9FJsY74ktV9gGmE8VErjCTGAdkq0NZxUZkhyp9/VY=
Received: from BY1PR10MB0374.namprd10.prod.outlook.com (10.162.144.28) by BY1PR10MB0456.namprd10.prod.outlook.com (10.162.145.153) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1080.14; Tue, 28 Aug 2018 04:04:00 +0000
Received: from BY1PR10MB0374.namprd10.prod.outlook.com ([fe80::2518:27f2:6df:a4c]) by BY1PR10MB0374.namprd10.prod.outlook.com ([fe80::2518:27f2:6df:a4c%6]) with mapi id 15.20.1080.015; Tue, 28 Aug 2018 04:04:00 +0000
From: Abhinava Shivakumar Sadasivarao <ASadasivarao@infinera.com>
To: "yang-doctors@ietf.org" <yang-doctors@ietf.org>
Thread-Topic: Clarification on YANG Schema Node Identifiers (wrt RPCs)
Thread-Index: AdQ+hCTiVQwhr86vSrOfK6NlBp3Pzw==
Date: Tue, 28 Aug 2018 04:04:00 +0000
Message-ID: <BY1PR10MB03749117566E8D57DAE66E37A20A0@BY1PR10MB0374.namprd10.prod.outlook.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: spf=none (sender IP is ) smtp.mailfrom=ASadasivarao@infinera.com;
x-originating-ip: [2601:646:8b01:a2e0:f4fe:c8c1:25c7:bf2b]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; BY1PR10MB0456; 6:IxOynnaOkDogXfKITLNh2ryq2is2QEeMx2HI9Pa3ucpo2/RI/fP+QvP2veF5bzUtA1FKOR2xPsE/MlgYnkiNX26R46rVNBIewFjz3n5lGLSvQUiacqaAFBex9SrUJJ9DSDn9ebJlt9LuqLCUzEcDfKwo1MbikHlfaYsscbky/abTt+gHRz4dWiQDKk8v65j0bA2KtbhsGxCtGzKJlPt6E+w7HkBGk+TgJaEpfOI69GLGrc8D8Z8SBiC1Iiw+LoWIb/dJ3BtxcxhJOVbnj9rGzmFAkn6ba7yvTMdFidJ/t38nTnkzFGFWQVcjhRmYGr9P73VSayKi19fkyeE/YEYLpx9jx4dKQRUZH5kjtekKgw3gZIJAD4m4h/s/3xfudcv33s8Vx1j+8vLARKDYW4H2PyZfW0dMfc+orGpog1PP4tJi+7Kg2+1ARaJiEFU1S/xlOt6cpGJHteB6pzAiLD3ejA==; 5:3t5aGffZIlebP3kGuXNE882DWVzwEujJycLcNikdyx2iBE5sSvb6cFEdJ/lPx9QepYkvPpzunBNyKpQd2LeM5Eiajx6wS2fhh7DXXWDInzrzA0c8VwlkkRys6mzbY+ZodIScNoCpsi04OnnqKYpp+T5PW4mH0+zBnq4zTykE/xA=; 7:ykFFh3aD+0HdYRYbryQGlaK8++aSQ/0mbGNmszrzPDs4xh7VqnY0smLll+/NAOsWvP1adoRN3s0OqPsa6Hll8kzfpfesi1/2xshl9lH8lzbPbGDjGaIGXXz4VhDGQjCxCCWwL9Vm5GRtmX9zzTI30ArGKhqtXsG/0pnFHWbVFyrIhOMVpmXJeVv0pQYJtAg3HZq1x3dkf8CSVad7eChPKT13ulbmeV8zRry81wdyNy/fFdtTCCPbGlQqzFup9GKS
x-ms-exchange-antispam-srfa-diagnostics: SOS;
x-ms-office365-filtering-correlation-id: cfcb23b4-8286-412f-5e2a-08d60c9b4945
x-microsoft-antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989137)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(2017052603328)(7153060)(7193020); SRVR:BY1PR10MB0456;
x-ms-traffictypediagnostic: BY1PR10MB0456:
x-microsoft-antispam-prvs: <BY1PR10MB0456F05E964563FF5A3D41F3A20A0@BY1PR10MB0456.namprd10.prod.outlook.com>
x-exchange-antispam-report-test: UriScan:(28532068793085)(21748063052155);
x-ms-exchange-senderadcheck: 1
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3002001)(3231311)(944501410)(52105095)(10201501046)(93006095)(93001095)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(20161123564045)(20161123560045)(20161123562045)(201708071742011)(7699016); SRVR:BY1PR10MB0456; BCL:0; PCL:0; RULEID:; SRVR:BY1PR10MB0456;
x-forefront-prvs: 077884B8B5
x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(39850400004)(396003)(136003)(366004)(346002)(376002)(199004)(189003)(2501003)(5250100002)(6916009)(81156014)(606006)(105586002)(53936002)(2351001)(106356001)(5630700001)(68736007)(478600001)(2900100001)(790700001)(81166006)(8676002)(6116002)(476003)(486006)(74316002)(2906002)(7736002)(5660300001)(80792005)(14454004)(72206003)(99286004)(25786009)(7696005)(97736004)(6506007)(186003)(5640700003)(6436002)(55016002)(236005)(9686003)(33656002)(54896002)(256004)(316002)(6306002)(102836004)(46003)(8936002)(86362001); DIR:OUT; SFP:1101; SCL:1; SRVR:BY1PR10MB0456; H:BY1PR10MB0374.namprd10.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1;
received-spf: None (protection.outlook.com: infinera.com does not designate permitted sender hosts)
x-microsoft-antispam-message-info: ffktHSU7expFPMZ6pyZoAneKniBuwLtbW0O2wxDrt0JqOH0TaaZ5YBCAiTubwJj0LyYFBL4gYCisCAl/UjUkK318D8Wey9Maxnz5sqUw81aSKe7YvqI9hbTxiFbwPPHPrervM5kS+sYbceqKvxI7o3g1GjUhRLCcs3HBjaV7COyjM2NeRpQRI/hAjp/VM2GZQhl53Icwx6yL3GjG1f5chc3/qmAoWf8ff+heLGJHeVYXhif9ib9HsBx8UwTgQ8Cglo0MOx+S01Ga8Beu6SFK16Dftl680iovtX2FZf3cEvmk0GFZ8eis2P0/RQwbOfLKk224m7qNeADXDXUssZZHJnq5gg4jTJRsxC0Orf4slyo=
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: multipart/alternative; boundary="_000_BY1PR10MB03749117566E8D57DAE66E37A20A0BY1PR10MB0374namp_"
MIME-Version: 1.0
X-OriginatorOrg: infinera.com
X-MS-Exchange-CrossTenant-Network-Message-Id: cfcb23b4-8286-412f-5e2a-08d60c9b4945
X-MS-Exchange-CrossTenant-originalarrivaltime: 28 Aug 2018 04:04:00.7089 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 285643de-5f5b-4b03-a153-0ae2dc8aaf77
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR10MB0456
Archived-At: <https://mailarchive.ietf.org/arch/msg/yang-doctors/LWzDvvSGekhnjBjVE4CechU4goQ>
X-Mailman-Approved-At: Tue, 28 Aug 2018 05:03:16 -0700
Subject: [yang-doctors] Clarification on YANG Schema Node Identifiers (wrt RPCs)
X-BeenThere: yang-doctors@ietf.org
X-Mailman-Version: 2.1.27
Precedence: list
List-Id: Email list of the yang-doctors directorate <yang-doctors.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/yang-doctors>, <mailto:yang-doctors-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/yang-doctors/>
List-Post: <mailto:yang-doctors@ietf.org>
List-Help: <mailto:yang-doctors-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/yang-doctors>, <mailto:yang-doctors-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 28 Aug 2018 04:05:47 -0000

Hello!

I had a question on YANG schema node identifiers as defined in the RFC 6020 (Section 6.5<https://tools.ietf.org/html/rfc6020#section-6.5>). As per the RFC:

A schema node identifier is a string that identifies a node in the schema tree.  It has two forms, "absolute" and "descendant", defined by the rules "absolute-schema-nodeid" and "descendant-schema-nodeid" in Section 12, respectively. A schema node identifier consists of a path of identifiers, separated by slashes ("/"). In an absolute schema node identifier, the first identifier after the leading slash is any top-level schema node in the local module or in all imported modules.

References to identifiers defined in external modules MUST be qualified with appropriate prefixes, and references to identifiers defined in the current module and its submodules MAY use a prefix. For example, to identify the child node "b" of top-level node "a", the string "/a/b" can be used.

My question is, can identifiers (absolute or otherwise) include nodes defined either in the input or output blocks of an RPC? From the example RPC<https://tools.ietf.org/html/rfc6020#section-7.13.5> in the RFC 6020:

        rpc rock-the-house {
             input {
                 leaf zip-code {
                     type string;
                 }
             }
         }

Can "/rock-the-house/input/zip-code" be considered a schema identifier, given the above description and the YANG grammar?
Section 7.13<https://tools.ietf.org/html/rfc6020#section-7.13> describes that the "rpc" statement defines an rpc node in the schema tree. So I would think the answer to the question is "Yes".

Thanks!
Abhinava