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

Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de> Tue, 31 July 2018 17:48 UTC

Return-Path: <j.schoenwaelder@jacobs-university.de>
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 A67BD130DC6; Tue, 31 Jul 2018 10:48:33 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 0
X-Spam-Level:
X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] 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 lfyFji9rdYjD; Tue, 31 Jul 2018 10:48:32 -0700 (PDT)
Received: from anna.localdomain (anna.eecs.jacobs-university.de [IPv6:2001:638:709:5::7]) by ietfa.amsl.com (Postfix) with ESMTP id 268C3130E5B; Tue, 31 Jul 2018 10:48:31 -0700 (PDT)
Received: by anna.localdomain (Postfix, from userid 501) id 018D423A578F; Tue, 31 Jul 2018 19:48:27 +0200 (CEST)
Date: Tue, 31 Jul 2018 19:48:27 +0200
From: Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>
To: Martin Bjorklund <mbj@tail-f.com>
Cc: evoit@cisco.com, yang-doctors@ietf.org, netconf@ietf.org
Message-ID: <20180731174827.n5r2jebon45s2cxy@anna.jacobs.jacobs-university.de>
Reply-To: Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>
Mail-Followup-To: Martin Bjorklund <mbj@tail-f.com>, evoit@cisco.com, yang-doctors@ietf.org, netconf@ietf.org
References: <727ae35abd394a85812168615acce2d3@XCH-RTP-013.cisco.com> <20180729.175356.1841285666617255654.mbj@tail-f.com> <77080682bf90495caec48436453e4750@XCH-RTP-013.cisco.com> <20180730.204142.1505732335534077415.mbj@tail-f.com>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: inline
In-Reply-To: <20180730.204142.1505732335534077415.mbj@tail-f.com>
User-Agent: NeoMutt/20180716
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/Mr7Www_JiWc7ym_q9IJEzFfUJrg>
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 17:48:34 -0000

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?

> 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".

/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/>