Re: [netmod] comments on draft-ietf-netmod-yang-instance-file-format-04

Balázs Lengyel <balazs.lengyel@ericsson.com> Sun, 17 November 2019 12:12 UTC

Return-Path: <balazs.lengyel@ericsson.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 B4B741200F8 for <netmod@ietfa.amsl.com>; Sun, 17 Nov 2019 04:12:33 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2
X-Spam-Level:
X-Spam-Status: No, score=-2 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_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=ericsson.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 3PqdJzVw0AON for <netmod@ietfa.amsl.com>; Sun, 17 Nov 2019 04:12:31 -0800 (PST)
Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-eopbgr150044.outbound.protection.outlook.com [40.107.15.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 234E91200F5 for <netmod@ietf.org>; Sun, 17 Nov 2019 04:12:31 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mkb5BtRtarzDjXALWNcbNLjryac8chjMIYUF2kjFZwQYykd6NbTxu5xsZbpP7sX/iLr8xZrHeRomugSn/aGCHrB90Dh//se1yg6ldWVlg8DbY4ybLKZp0F8MNWVDUlWRfb/UsUeR7Qs7IO3d1FUZNWBf0DBLkSvdY55/ICPhm79I5mYU00x1J6DIjhn0yCImqAOdUz9JNrM8c/wJ9Hpx70lLS8geyaUIurUGG2C0cIY+xrbABVdeFVnDZIIvIxc8TUKZh/BbL3IJDN4wZED5UgD/f/BGq37LwrvVu5pjnC3OZNpx9z21HLow0iTH3nUJQXPuo9x71464y0zo7z3Qcw==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/3toKasvEIrEQl1QAuwweEB3kO1tobo08ICnYO61LZc=; b=icEfR3SnUnMwXA4rtXQCB0ncyWoVh06m0/2x1R7GSiubcnMEhuyUdcgkyn/Uo2IiyG82tlTKpLJizhJcZAg/G9/tceX7Hd5A77B7/chHMcD47EV2gw/va+2GozireRlbInttRXwl16TrOHKskBVt1wqsTZtSYMLe0Xwx0u6M9CjxZqpgKzIS2ic71DTyH2ickxdz/oUsjED6b0u+pCifwlk/Es1kKUUf6pciWftY6DR0mRp6ETCF9kD05YUrwnNZpvrpZMg/XS3d9VYrqOfEa7X5xfloFMFgaAPxLu92esmriVRLUWoMS+UcU3do/tHM3L4tzPWYhceRlKTv1A6YlA==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ericsson.com; dmarc=pass action=none header.from=ericsson.com; dkim=pass header.d=ericsson.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ericsson.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/3toKasvEIrEQl1QAuwweEB3kO1tobo08ICnYO61LZc=; b=hdhAammrVsefe3f1zj9amdD1cGuytXD/UEDTGb7mehZjaJWFE+wFNCzHbjexH5gvn09QsCG9a8CtBuhp8aOoWGwQPZvf0AKhTP+mXf+bMETcDH1wwVtb8b9PONYOr6UpmjZt4NjJoLmM0kkG0gtPr5MIgBWt62SN2dMSAH3mskg=
Received: from AM7PR07MB6214.eurprd07.prod.outlook.com (10.186.170.77) by AM7PR07MB6248.eurprd07.prod.outlook.com (10.186.168.203) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2474.9; Sun, 17 Nov 2019 12:12:28 +0000
Received: from AM7PR07MB6214.eurprd07.prod.outlook.com ([fe80::749e:982d:1c62:367b]) by AM7PR07MB6214.eurprd07.prod.outlook.com ([fe80::749e:982d:1c62:367b%4]) with mapi id 15.20.2474.012; Sun, 17 Nov 2019 12:12:28 +0000
From: =?utf-8?B?QmFsw6F6cyBMZW5neWVs?= <balazs.lengyel@ericsson.com>
To: Andy Bierman <andy@yumaworks.com>
CC: Martin Bjorklund <mbj@tail-f.com>, NetMod WG <netmod@ietf.org>
Thread-Topic: [netmod] comments on draft-ietf-netmod-yang-instance-file-format-04
Thread-Index: AQHVf2MbQga78mSle0Opwa3noseNw6dUAaKAgCraSXCAABVPAIAQZweQ
Date: Sun, 17 Nov 2019 12:12:28 +0000
Message-ID: <AM7PR07MB6214AD2971F93D81FAF24752F0720@AM7PR07MB6214.eurprd07.prod.outlook.com>
References: <20191010.140525.904627955349075516.mbj@tail-f.com> <CABCOCHShFd41gcGLTSjJQMWCA4Ak_QX2iHpng_6DBqLRf23vqw@mail.gmail.com> <AM7PR07MB62148A605167BD4D046A2E3DF0790@AM7PR07MB6214.eurprd07.prod.outlook.com> <CABCOCHT0G+4zT2ApvRA1rgO3j4BR0gEbeiP4XDWV0nq4rxjxGQ@mail.gmail.com>
In-Reply-To: <CABCOCHT0G+4zT2ApvRA1rgO3j4BR0gEbeiP4XDWV0nq4rxjxGQ@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach: yes
X-MS-TNEF-Correlator:
authentication-results: spf=none (sender IP is ) smtp.mailfrom=balazs.lengyel@ericsson.com;
x-originating-ip: [31.133.152.152]
x-ms-publictraffictype: Email
x-ms-office365-filtering-correlation-id: 1f0ce5ee-af3e-4f96-09aa-08d76b576a61
x-ms-traffictypediagnostic: AM7PR07MB6248:
x-microsoft-antispam-prvs: <AM7PR07MB624875B724FE69ABDB7FA768F0720@AM7PR07MB6248.eurprd07.prod.outlook.com>
x-ms-oob-tlc-oobclassifiers: OLM:7691;
x-forefront-prvs: 02243C58C6
x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(366004)(376002)(136003)(346002)(396003)(39860400002)(199004)(189003)(606006)(71190400001)(26005)(25786009)(54896002)(14454004)(236005)(85182001)(66556008)(9686003)(6246003)(66946007)(66616009)(66476007)(74316002)(102836004)(6916009)(6306002)(66446008)(64756008)(4326008)(6506007)(66066001)(53546011)(7736002)(33656002)(966005)(76116006)(478600001)(790700001)(6116002)(3846002)(186003)(229853002)(71200400001)(66574012)(8676002)(86362001)(54906003)(486006)(6436002)(476003)(256004)(85202003)(99286004)(52536014)(5660300002)(55016002)(81166006)(81156014)(7696005)(76176011)(11346002)(8936002)(316002)(446003)(2906002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM7PR07MB6248; H:AM7PR07MB6214.eurprd07.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1;
received-spf: None (protection.outlook.com: ericsson.com does not designate permitted sender hosts)
x-ms-exchange-senderadcheck: 1
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: yPEUDVEs0y/Zi6cVmsxBXC3YFRQ95pNIq0Y/MEaayTRQ0cwEtnpibBuNDY5pR1mKyP/4EZGPaE3FUFvXNt5xTjzQQsKiTF2zg/7TzhtmNcDdtqlukxdrk0g03finCiPiI8Xba4XkqJWqs9Kb+om8jjUZQWdzkVgDxSmiAAuIHmdEFHWZBrMTBbMj7iXIaXGnI6yIb+pAJEo9C3EXKi6ahRouuurukY314Ndj4XHUt7rzLAIshnm0mcG572nwwITvaWky+eBmC45t3UjH/9V0I/Hh8ow7m12+kcj1bW8+jhaQah/XcQcwG37CpXOjFuIVScdNL2y9MBU9fedg6DPRCG+mEswpQk05u7WFmGAkcGmI2/PUaisIIYCBs7fydilavBIqbtP9T/OGZvUNqjVwR7FH/8EiFWko8U99aJjTSpdhCl+Idf/W7nFsZ/ql+rRM
x-ms-exchange-transport-forked: True
Content-Type: multipart/signed; protocol="application/x-pkcs7-signature"; micalg=SHA1; boundary="----=_NextPart_000_028F_01D59D83.53CF5170"
MIME-Version: 1.0
X-OriginatorOrg: ericsson.com
X-MS-Exchange-CrossTenant-Network-Message-Id: 1f0ce5ee-af3e-4f96-09aa-08d76b576a61
X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Nov 2019 12:12:28.5085 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 92e84ceb-fbfd-47ab-be52-080c6b87953f
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: EOKTlqhA61/SRDYcVUyhKxK4XoSsKAySrMWrryHFHIiCveKZLWWLm2YhpflyjokhzuQ1jzRMxyN3/ol8kB+sphZyMCzDqLZ9UNFEb+WwJ+Y=
X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM7PR07MB6248
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/nOKnsiJpNXLCdqPhFzY94uivr7E>
Subject: Re: [netmod] comments on draft-ietf-netmod-yang-instance-file-format-04
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: Sun, 17 Nov 2019 12:12:34 -0000

1 comment accepted, 1 explained. See below BALAZS2. 

 

From: Andy Bierman <andy@yumaworks.com> 
Sent: 2019. november 7., csütörtök 7:15
To: Balázs Lengyel <balazs.lengyel@ericsson.com>
Cc: Martin Bjorklund <mbj@tail-f.com>om>; NetMod WG <netmod@ietf.org>
Subject: Re: [netmod] comments on draft-ietf-netmod-yang-instance-file-format-04

 

On Thu, Oct 10, 2019 at 5:06 AM Martin Bjorklund <mbj@tail-f.com <mailto:mbj@tail-f.com> > wrote:


  o  leaf-list module

    The type of this leaf-list is a string with:

      pattern '.+@\d{4}-\d{2}-\d{2}\.yang'yang';

    I think the revision needs to be optional, and the suffix ".yang"
    dropped, since it doesn't add any value:

      pattern '.+(@\d{4}-\d{2}-\d{2})?';

   (same for inline-spec).

 

IMO the filespec SHOULD follow the pattern in  https://tools.ietf.org/html/rfc7950#section-5.2

BALAZS: It does follow the pattern except that I made the revision date mandatory. It is needed to properly understand the instance data.

 

 

The representation (.yang vs .yin) is not relevant here.

Revision statements are optional in a YANG module, so what fake date string do you

use if the module has no revision?  Seems prudent to make the date-string optional in the filename.

 

 

BALAZS2: OK, date mandatory only  if present in the yang module, otherwise absent. I will add .yin as an alternative.

I would like to keep the \.((yang)|(yin)) part in the pattern as 

 <mailto:ietf-yang-type@2015-12-07.yang> ietf-yang-type@2015-12-07.yang

looks more familiar than just

ietf-yang-types@2019-12-07

 

+1, except not in favor of so many ways to specify schema.

That means the file reader MUST support all of them.

 

BALAZS: All 3 formats have been explicitly requested by earlier commenters. I see a rational for each:

Simplified-inline: it is simple and usually enough

Inline: if you need to specify not just the modules but also the supported features and deviations you need this full format

Uri: if you don’t really want to specify the content-schema in detail, e.g., because you are generating many files with the same schema, all you need is reference that identifies the content-schema

 

Which one would you like to implementing? Maybe we could make the inline method optional with a feature (feature if-feature),

 

 

I will just deviate out the stuff not worth implementing. ;-)

I prefer the schema-uri approach but simplified-inline is probably easiest to implement.

 

The schema-uri looks standard but the contents of the referenced YANG instance file can be

anything (as opposed to a pre-defined YANG template like /yang-library).

 

The inline-content-schema object looks broken because a YANG file is a text string.

How does one use anydata to encode a text string? (It must be a container of YANG data nodes).

Even the YIN representation is not a set of YANG data nodes, so anydata encoding seems wrong.

Including all the YANG modules in this file seems especially heavyweight.

(I have no intention of supporting this mode.)

BALAZS2: This does not contain the YANG files themselves, rather something like instance data for the ietf-yang-library.

So it is anydata.

Sometimes specifying deviations and supported features may be needed. Also Jurgen wanted a flexible solution.

As a private comment: you may deviate it out (I can’t say this officialy :-)  )

 

 

Andy

 

 

Andy

 

_______________________________________________
netmod mailing list
netmod@ietf.org <mailto:netmod@ietf.org> 
https://www.ietf.org/mailman/listinfo/netmod