Re: [YANG] meaning of unique in PDUs

Ladislav Lhotka <lhotka@cesnet.cz> Fri, 25 January 2008 14:03 UTC

Return-path: <yang-bounces@ietf.org>
Received: from [127.0.0.1] (helo=stiedprmman1.va.neustar.com) by megatron.ietf.org with esmtp (Exim 4.43) id 1JIP9b-0004Cw-U3; Fri, 25 Jan 2008 09:03:35 -0500
Received: from yang by megatron.ietf.org with local (Exim 4.43) id 1JIP9b-0004Cd-44 for yang-confirm+ok@megatron.ietf.org; Fri, 25 Jan 2008 09:03:35 -0500
Received: from [10.91.34.44] (helo=ietf-mx.ietf.org) by megatron.ietf.org with esmtp (Exim 4.43) id 1JIP9a-0004CR-Py for yang@ietf.org; Fri, 25 Jan 2008 09:03:34 -0500
Received: from office2.cesnet.cz ([195.113.144.244]) by ietf-mx.ietf.org with esmtp (Exim 4.43) id 1JIP9Z-0007Cd-4L for yang@ietf.org; Fri, 25 Jan 2008 09:03:34 -0500
Received: from [172.29.2.201] (asus-gx.lhotka.cesnet.cz [195.113.161.161]) by office2.cesnet.cz (Postfix) with ESMTP id 8C69FD800C4 for <yang@ietf.org>; Fri, 25 Jan 2008 15:03:32 +0100 (CET)
Subject: Re: [YANG] meaning of unique in PDUs
From: Ladislav Lhotka <lhotka@cesnet.cz>
To: yang@ietf.org
In-Reply-To: <20080125.134417.43491219.mbj@tail-f.com>
References: <200801250311.m0P3Bhbo036061@idle.juniper.net> <1201262219.24635.125.camel@missotis> <20080125.134417.43491219.mbj@tail-f.com>
Content-Type: text/plain; charset=utf-8
Organization: CESNET
Date: Fri, 25 Jan 2008 15:03:32 +0100
Message-Id: <1201269812.24635.181.camel@missotis>
Mime-Version: 1.0
X-Mailer: Evolution 2.12.1
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: 0.0 (/)
X-Scan-Signature: 4adaf050708fb13be3316a9eee889caa
X-BeenThere: yang@ietf.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: YANG modeling Language for NETCONF <yang.ietf.org>
List-Unsubscribe: <https://www1.ietf.org/mailman/listinfo/yang>, <mailto:yang-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www1.ietf.org/pipermail/yang>
List-Post: <mailto:yang@ietf.org>
List-Help: <mailto:yang-request@ietf.org?subject=help>
List-Subscribe: <https://www1.ietf.org/mailman/listinfo/yang>, <mailto:yang-request@ietf.org?subject=subscribe>
Errors-To: yang-bounces@ietf.org

Martin Bjorklund píše v Pá 25. 01. 2008 v 13:44 +0100:
> Ladislav Lhotka <lhotka@cesnet.cz> wrote:
> > Phil Shafer píše v Čt 24. 01. 2008 v 22:11 -0500:
> > > >In some cases this mapping is automatic, some cases are defined in the
> > > >YANG draft and some are not clear yet (to me at least).
> > > 
> > > Please let me know where it isn't clear and we can fix the draft.
> > > 
> > Here is one: what's the interpretation (if any) of the unique statement
> > for PDUs?
> 
> The draft says:
> 
>   The "unique" statement is used to put constraints on valid
>   configurations. [...]

Yup, but Phil claimed:
YANG defines constraints on the XML that passes between the client and
server.

> 
>   In a valid configuration, the combined values of all the leaf
>   instances specified in the string MUST be unique within all list
>   entry instances.
> 
> Maybe we should be more clear what we mean with "valid configuration"?

Yes, there seem to be at least four different meanings.

> This isn't really a "unique" or "key" question; it is a datatype
> equestion.  In this case, the YANG built-in type "string" behaves as

Sure, but here it is quite crucial. Shouldn't YANG perhaps include a
built-in type equivalent to xs:token for these purposes?

> "xs:string", so no whitespace normalization is done.
> 

Lada

-- 
Ladislav Lhotka, CESNET
PGP Key ID: E74E8C0C



_______________________________________________
YANG mailing list
YANG@ietf.org
https://www1.ietf.org/mailman/listinfo/yang