Subject: Re: [netmod] "A YANG Data Model for Routing Management" Modifications

From: Ladislav Lhotka <[email-masked]>
Date: Wed, 1 Jun 2016 11:45:11 +0200

> On 01 Jun 2016, at 08:39, Juergen Schoenwaelder <[email-masked]> wrote:
> 
> On Tue, May 31, 2016 at 11:02:41PM +0200, Martin Bjorklund wrote:
>> "Acee Lindem (acee)" <[email-masked]> wrote:
>>> Hi Lada, 
>>> If we can’t get YANG to do what we need, can we just support a choice with
>>> a special value of “unspecified” for the interface and address?
>> 
>> Yes, you can make these keys be unions of interface-ref and an enum
>> 'unspecified', and an ip-address and enum 'unspecified'.
>> 
>>> Additionally, we’d need a constraint that enforces the fact that both
>>> interface and address cannot be “unspecified”.
>> 
>>   must 'key1 != "unspecified" or key2 != "unspecified"';
>> 
> 
> Does this not mean you can't have an interface named 'unspecified'
> anymore? Perhaps we should have disallowed zero-length string values
> for /interfaces/interface/name and then we would have a handy value
> to be used in situations like this?

Yes, I think the empty string is better than any magic value.

Lada

> 
> /js
> 
> -- 
> Juergen Schoenwaelder           Jacobs University Bremen gGmbH
> Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
> Fax:   +49 421 200 3103         <http://www.jacobs-university.de/>
> 
> _______________________________________________
> netmod mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/netmod

--
Ladislav Lhotka, CZ.NIC Labs
PGP Key ID: E74E8C0C