[OPSAWG] Question on how to design a Yang model to reflect auto-asignment of a give leaf

Oscar González de Dios <oscar.gonzalezdedios@telefonica.com> Tue, 11 February 2020 02:40 UTC

Return-Path: <oscar.gonzalezdedios@telefonica.com>
X-Original-To: opsawg@ietfa.amsl.com
Delivered-To: opsawg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 3432A1200B6; Mon, 10 Feb 2020 18:40:21 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.001
X-Spam-Level:
X-Spam-Status: No, score=-2.001 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] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=telefonica.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 nWtYMBbHsSdH; Mon, 10 Feb 2020 18:40:18 -0800 (PST)
Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-eopbgr150137.outbound.protection.outlook.com [40.107.15.137]) (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 801BF120058; Mon, 10 Feb 2020 18:40:17 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lJ1dre3n1xk/BGNVZd6YF72QaCX2UpG/iH1QjofSx1d4mqFtoTqGHK8O4Bqol4cC78/cZv/6HtIBUKL2lddgJQZd/3rzQAd1ICHC9tsY2tv3MYnSUOyEknWC0U0YsHNtrhtSPznLdJXcxiWSSEijsK6OA0xBqu4hGIykfRmJps6zIQOzRhkjuLsg3rhnXWaxkuwEpDQsRYNBSn7VHtG2tP8SHwqbR6+QJo0M9d6OdMYvT1JjNYff3V6CgFMTxKyeexUAiFqs8kIOUqtzcTZW2eTTB8Q0PDReBFbfsGnGwmcDxkF7QByTy0y05XiOdtyu1m3KheBo//s0UUq0IxKtBg==
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=qMP0bqIhFzHRe8/4q0BZRzm6TDCAWf6Q3xnvkn2rLig=; b=UAbfKGhhr3qy1Q9yFh/ImNXUpy5yNQ49bcNeGYXIdlq22mtioSILU3yy/JpCdcjmyua9aW1R3nDxiesDsQmRAR6VOYvdXeweXB4a6Gzep8G/CHBh+sPLZ94fAfWqenU7U/vE8MutBc6khiZfAAM3zXDHI4zS+6yMX5OleiuJ7rnrC8TxyPlbYTOdTXo4buRGmdW2v/SUY7eCUwmq/yQgpntJvGizgFnMzV/sIO/ofPJZVuvUWRbe1IeczNmI0BKZu+OQsZmNkJ8W2Yf/eEc4QatOuTFcowFjv/fvrAvc30SCKb0ZlQkF7Lw0TWwcQSHnYfl09+Q+5CqvwqLcVPuFVg==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=telefonica.com; dmarc=pass action=none header.from=telefonica.com; dkim=pass header.d=telefonica.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telefonica.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qMP0bqIhFzHRe8/4q0BZRzm6TDCAWf6Q3xnvkn2rLig=; b=pN1ZajncVFszuujdU327/29I8Fu/rsIlcJXif0nUcQB0aTA1nyvZi76iAImhNFhgs+TXJiyyvHbS28/2D/ItMGI8T2cV1ibBdUV4ziRRKfRRONskkgC8QGwgotEIFFdur3efoUHt1vKHl2hOby6QAx2AwF/RIK69s/Sl1YH6Ki4=
Received: from AM6PR06MB5653.eurprd06.prod.outlook.com (20.178.93.90) by AM6PR06MB5062.eurprd06.prod.outlook.com (20.177.191.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2707.27; Tue, 11 Feb 2020 02:40:14 +0000
Received: from AM6PR06MB5653.eurprd06.prod.outlook.com ([fe80::4d14:ef4b:8837:87c5]) by AM6PR06MB5653.eurprd06.prod.outlook.com ([fe80::4d14:ef4b:8837:87c5%7]) with mapi id 15.20.2707.030; Tue, 11 Feb 2020 02:40:14 +0000
From: Oscar González de Dios <oscar.gonzalezdedios@telefonica.com>
To: "opsawg@ietf.org" <opsawg@ietf.org>, "netmod@ietf.org" <netmod@ietf.org>
Thread-Topic: Question on how to design a Yang model to reflect auto-asignment of a give leaf
Thread-Index: AdXgf2dbJ6WUxXgzRxKVGs1XfT3HEw==
Date: Tue, 11 Feb 2020 02:40:14 +0000
Message-ID: <AM6PR06MB5653DFBCFC89E54F28E45AECFD180@AM6PR06MB5653.eurprd06.prod.outlook.com>
Accept-Language: es-ES, en-US
Content-Language: es-ES
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: spf=none (sender IP is ) smtp.mailfrom=oscar.gonzalezdedios@telefonica.com;
x-originating-ip: [186.231.32.211]
x-ms-publictraffictype: Email
x-ms-office365-filtering-ht: Tenant
x-ms-office365-filtering-correlation-id: b72a324b-b456-48ee-34f8-08d7ae9bb944
x-ms-traffictypediagnostic: AM6PR06MB5062:
x-microsoft-antispam-prvs: <AM6PR06MB506229B97EBC8F5412822BFEFD180@AM6PR06MB5062.eurprd06.prod.outlook.com>
x-ms-oob-tlc-oobclassifiers: OLM:10000;
x-forefront-prvs: 0310C78181
x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(4636009)(39860400002)(366004)(136003)(346002)(376002)(396003)(189003)(199004)(186003)(52536014)(7696005)(86362001)(71200400001)(478600001)(5660300002)(450100002)(8676002)(9686003)(316002)(6506007)(786003)(66946007)(33656002)(76116006)(66476007)(81156014)(81166006)(66556008)(66446008)(64756008)(110136005)(26005)(8936002)(55016002)(19627235002)(66574012)(2906002)(9010500006); DIR:OUT; SFP:1102; SCL:1; SRVR:AM6PR06MB5062; H:AM6PR06MB5653.eurprd06.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1;
received-spf: None (protection.outlook.com: telefonica.com does not designate permitted sender hosts)
x-ms-exchange-senderadcheck: 1
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: m3YrrUd/Jn6UqQEAeF2wmArqWOH7mY9usHcHbqo9TAIvCDcSkW0MOC1zwzXBqQv8MK+fDkJ42d6sFUp+7h9kcaUSKhY2hGL789wt8i105s1dgaKXJqtmKyNjGXlFoJ/TZE3tRvNgjvJ7Popi+/2xY/dYREqrfQRTUmfeg16uLyUyoCe5KsyaP6BMdC9VYOGdxdzIB/LSw4hEwAlAhEHFVkZYdjGECxeinnby+jX08uQ3iTyssMrXEMU9k0M9hMkzJZ+HzuRQ0F80Z7XV78bl95dYcJhHkWy7+P/vDcg69Gy7YL/s4m2uBYJWjxZJ+RGonHd2uEWJHVxHGt0RXEq8vwQToRbFd0UruptIHI5UocmAGzrtztGusF3/P8SCnARdb0YOas4oJ0DFTtjoeBtGinLk0mJ+NzuP4i0LSirTTYnQI1oIA/U6pV0FN/TLZs6hZsohkzlyUp9B7mjikEAuBVSb5ajjI/N14OsHQ2+wxhz76u1bEJTBNBPOj7iVWpqd
x-ms-exchange-antispam-messagedata: GYCCfyZWyJSZTWgi726FLWnxuh1aqR8wVc4qy1pqBME/3kkgXYCuN0fGY8dAUGOJ2Pei6QOwGl0VWHyjikyVl0rNNl5CdhEn03rQh97WeqkNf11e30owvepM01/zdThWAMvEX0ekUPltELLDcj2X8Q==
x-ms-exchange-transport-forked: True
Content-Type: multipart/alternative; boundary="_000_AM6PR06MB5653DFBCFC89E54F28E45AECFD180AM6PR06MB5653eurp_"
MIME-Version: 1.0
X-OriginatorOrg: telefonica.com
X-MS-Exchange-CrossTenant-Network-Message-Id: b72a324b-b456-48ee-34f8-08d7ae9bb944
X-MS-Exchange-CrossTenant-originalarrivaltime: 11 Feb 2020 02:40:14.6424 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 9744600e-3e04-492e-baa1-25ec245c6f10
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: iRNzeEKSlXgnJ8smHUQWT0ZlefnSZhdcEqs6YCYCDEMTEYyKGVgJpuWmEllrDLx8sj+gSJ/QAsp9ZogOh2w4J+jt5aRWY6Bbw1ygk7lSozZKVbK5zd6Q9vrLHKmkEFzs
X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR06MB5062
Archived-At: <https://mailarchive.ietf.org/arch/msg/opsawg/TmtSBujK87APnzqv6NKCu_k6Y3g>
Subject: [OPSAWG] Question on how to design a Yang model to reflect auto-asignment of a give leaf
X-BeenThere: opsawg@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: OPSA Working Group Mail List <opsawg.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/opsawg>, <mailto:opsawg-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/opsawg/>
List-Post: <mailto:opsawg@ietf.org>
List-Help: <mailto:opsawg-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/opsawg>, <mailto:opsawg-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 11 Feb 2020 02:40:21 -0000

Dear OPSAWG and Netmod colleagues,

                During last IETF Opsawg meeting we raised a question (and there was some discussion during the meeting) that we have found yet no good answer and we would like to discuss it with operations and Yang experts.

                The use case is the following:  We have a yang module which holds certain optional leafs. The behaviors that we would like to have (and distinguish between them) are:


a)       The user does not provide the value and such value is auto-assigned by the system (a  device (if it is a device module) or a controller (if it is a network/service module)).

b)      The user does not provide a value and wants that such value IS NOT set by the system (as assigning a value has implications). That is, intentionally it is aimed at being left "empty" and should not be expanded. So, either the value is set or should remain empty

What is the best way to model this behavior? I see that some yang modules have added an "auto-assignment" leaf to express if auto-assignment is desired or not. (hence, auto-assignment false, and leaf not set, would  do not assign).

Which is the "default" rule for a leaf that is not set? It is that the system is free to create it (via template or any means of auto-assignment) or should leave it as is, that is, empty?

In NMDA, the system is allowed to expand a given configuration. This fact, in my personal view,  implies that by "default" any system could implement the "auto-assignment" behavior being compliant with Neconf/Restconf/NMDA rules (but I am not sure if the interpretation is correct).

Best Regards,

                Óscar

________________________________

Este mensaje y sus adjuntos se dirigen exclusivamente a su destinatario, puede contener información privilegiada o confidencial y es para uso exclusivo de la persona o entidad de destino. Si no es usted. el destinatario indicado, queda notificado de que la lectura, utilización, divulgación y/o copia sin autorización puede estar prohibida en virtud de la legislación vigente. Si ha recibido este mensaje por error, le rogamos que nos lo comunique inmediatamente por esta misma vía y proceda a su destrucción.

The information contained in this transmission is privileged and confidential information intended only for the use of the individual or entity named above. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this transmission in error, do not read it. Please immediately reply to the sender that you have received this communication in error and then delete it.

Esta mensagem e seus anexos se dirigem exclusivamente ao seu destinatário, pode conter informação privilegiada ou confidencial e é para uso exclusivo da pessoa ou entidade de destino. Se não é vossa senhoria o destinatário indicado, fica notificado de que a leitura, utilização, divulgação e/ou cópia sem autorização pode estar proibida em virtude da legislação vigente. Se recebeu esta mensagem por erro, rogamos-lhe que nos o comunique imediatamente por esta mesma via e proceda a sua destruição