Re: [Netconf] [yang-doctors] YANG Doctor question: empty mandatory choice?

Martin Bjorklund <mbj@tail-f.com> Tue, 31 July 2018 19:02 UTC

Return-Path: <mbj@tail-f.com>
X-Original-To: netconf@ietfa.amsl.com
Delivered-To: netconf@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8F4AA130DC6; Tue, 31 Jul 2018 12:02:20 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.001
X-Spam-Level:
X-Spam-Status: No, score=-0.001 tagged_above=-999 required=5 tests=[SPF_PASS=-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 29WHP8seKY2a; Tue, 31 Jul 2018 12:02:18 -0700 (PDT)
Received: from mail.tail-f.com (mail.tail-f.com [46.21.102.45]) by ietfa.amsl.com (Postfix) with ESMTP id 34DCC130E60; Tue, 31 Jul 2018 12:02:18 -0700 (PDT)
Received: from localhost (h-80-27.A165.priv.bahnhof.se [212.85.80.27]) by mail.tail-f.com (Postfix) with ESMTPSA id 3776B1AE0426; Tue, 31 Jul 2018 21:02:17 +0200 (CEST)
Date: Tue, 31 Jul 2018 21:02:17 +0200
Message-Id: <20180731.210217.102849326902496921.mbj@tail-f.com>
To: j.schoenwaelder@jacobs-university.de
Cc: evoit@cisco.com, yang-doctors@ietf.org, netconf@ietf.org
From: Martin Bjorklund <mbj@tail-f.com>
In-Reply-To: <20180731174827.n5r2jebon45s2cxy@anna.jacobs.jacobs-university.de>
References: <77080682bf90495caec48436453e4750@XCH-RTP-013.cisco.com> <20180730.204142.1505732335534077415.mbj@tail-f.com> <20180731174827.n5r2jebon45s2cxy@anna.jacobs.jacobs-university.de>
X-Mailer: Mew version 6.7 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO)
Mime-Version: 1.0
Content-Type: Text/Plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/Ye41O_2-NjjD-RTGocTX0bpMZX4>
Subject: Re: [Netconf] [yang-doctors] YANG Doctor question: empty mandatory choice?
X-BeenThere: netconf@ietf.org
X-Mailman-Version: 2.1.27
Precedence: list
List-Id: Network Configuration WG mailing list <netconf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netconf>, <mailto:netconf-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netconf/>
List-Post: <mailto:netconf@ietf.org>
List-Help: <mailto:netconf-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netconf>, <mailto:netconf-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 31 Jul 2018 19:02:21 -0000

Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de> wrote:
> On Mon, Jul 30, 2018 at 08:41:42PM +0200, Martin Bjorklund wrote:
> > 
> > The empty mandatory choice does provide value since it requires that
> > some transport-specific parameters are configured.  However, can we
> > assume that all transports require configuration parameters here?
> 
> Can you have a receiver without any transport parameters?

Who knows?  Maybe the transport parameters are obvious and static?


> > It is probably safest to not have a mandatory choice, and instead ensure
> > that each transport augements the proper params -- and since this is
> > YANG 1.1, the transport params that are augmented can actually be
> > marked as mandatory.
> 
> Frankly, an empty mandatory choice quite clearly says "this is
> incomplete and unusable without an augmentation".

Yes.  The question is if we can guarantee that *all* transoports
*require* configuration params.


/martin


> 
> /js
> 
> -- 
> Juergen Schoenwaelder           Jacobs University Bremen gGmbH
> Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
> Fax:   +49 421 200 3103         <https://www.jacobs-university.de/>
>