Re: [Yot] questions concerning sid value assignments

peter van der Stok <stokcons@xs4all.nl> Tue, 20 February 2018 08:40 UTC

Return-Path: <stokcons@xs4all.nl>
X-Original-To: yot@ietfa.amsl.com
Delivered-To: yot@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E856B1243F3 for <yot@ietfa.amsl.com>; Tue, 20 Feb 2018 00:40:32 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.62
X-Spam-Level:
X-Spam-Status: No, score=-2.62 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, URIBL_BLOCKED=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 oQ54iFgNSrLd for <yot@ietfa.amsl.com>; Tue, 20 Feb 2018 00:40:31 -0800 (PST)
Received: from lb1-smtp-cloud9.xs4all.net (lb1-smtp-cloud9.xs4all.net [194.109.24.22]) (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 72EA2124239 for <yot@ietf.org>; Tue, 20 Feb 2018 00:40:31 -0800 (PST)
Received: from webmail.xs4all.nl ([IPv6:2001:888:0:22:194:109:20:216]) by smtp-cloud9.xs4all.net with ESMTPA id o3TReH4jQoWCOo3TRejCrg; Tue, 20 Feb 2018 09:40:29 +0100
Received: from AMontpellier-654-1-186-134.w92-145.abo.wanadoo.fr ([92.145.165.134]) by webmail.xs4all.nl with HTTP (HTTP/1.1 POST); Tue, 20 Feb 2018 09:40:29 +0100
MIME-Version: 1.0
Content-Type: text/plain; charset="US-ASCII"; format="flowed"
Content-Transfer-Encoding: 7bit
Date: Tue, 20 Feb 2018 09:40:29 +0100
From: peter van der Stok <stokcons@xs4all.nl>
To: Michael Richardson <mcr+ietf@sandelman.ca>
Cc: consultancy@vanderstok.org, yot@ietf.org, Michel Veillette <Michel.Veillette@trilliantinc.com>, "Panos Kampanakis (pkampana)" <pkampana@cisco.com>, Kent Watsen <kwatsen@juniper.net>
Organization: vanderstok consultancy
Reply-To: consultancy@vanderstok.org
Mail-Reply-To: consultancy@vanderstok.org
In-Reply-To: <8136.1519064595@obiwan.sandelman.ca>
References: <faa44e95aa561876f119edc7358fd118@xs4all.nl> <26096.1518551413@obiwan.sandelman.ca> <9e0d297ad888a36e16921d10873cc947@xs4all.nl> <BN6PR06MB23082D66ED7486BDA002B1DBFEF50@BN6PR06MB2308.namprd06.prod.outlook.com> <eaccba06f07bc88eac32285fb8880f06@xs4all.nl> <22cc48128046319c662c116bcc39d761@xs4all.nl> <8136.1519064595@obiwan.sandelman.ca>
Message-ID: <541bb64fbea71cf95ab50caadcf37a60@xs4all.nl>
X-Sender: stokcons@xs4all.nl
User-Agent: XS4ALL Webmail
X-CMAE-Envelope: MS4wfEvDkCvCsqVZOkTFPMRJXTVWhavFHoHLNxD38OpvE7td3Yzw2T6XCWqyvMh5G2wwpGb+Nfj2jRdddsbG0v4pOerjEiupQs0vBZaDbsJaXgSr3QrsQOr2 mC/X+e1SfET4u7HV2UjYq7MRIqt9fEc0MLUj+OgPhBDYSeAiT51MMn1exId445/nW02sbq+88A/p7rcjTaOfOu9i4Fok/a5x/upBvWRguI3+QxEio9fbZ2AY sfQ7tWyk4USyjDSv0QV7/bnugPAEku5/XsNmztPlzHqVmOM5mrA4arEz6i/ab3KWMccleGdLZd4wnU/tgNhi5PB6gMi6nPzrKKRiB92b8kMRsI5VH4OOAPaG B39m9O3A+ojTomeQI4y/4oaPe8Ofgg==
Archived-At: <https://mailarchive.ietf.org/arch/msg/yot/aGa5kq9zOwg8UrphUi653thrrO0>
Subject: Re: [Yot] questions concerning sid value assignments
X-BeenThere: yot@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: Yang of Things <yot.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/yot>, <mailto:yot-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/yot/>
List-Post: <mailto:yot@ietf.org>
List-Help: <mailto:yot-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/yot>, <mailto:yot-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Feb 2018 08:40:33 -0000


Michael Richardson schreef op 2018-02-19 19:23:
> peter van der Stok <stokcons@xs4all.nl> wrote:
>     > I created an example for myself by heart. Can you see if my
> memory is still
>     > correct?
> 
>     > I assume a server with one voucher module and one cwt-voucher 
> module;
>     > The augment with grouping is used for SID allocation.
>     > The diagnostic notation is used for CBOR.
> 
> Cool...
> 
>     > {
>     > 1001000: {
>     > +3 : "2016-10-07T19:31:42Z",
> 
>     > A returned cwt-voucher may look like:
> 
>     > {
>     > 1001030: {
>     > -27 : "2016-10-07T19:31:42Z",
> 
> It took me a moment to figure out that 1001000+3 == 1001030-27.
> That's exactly what I would think should happen if we have SIDs 
> allocate for
> the underlying ietf-voucher object which we then repeat.
> 
> There is a concern if the gap between 1001000 and 1001030 was larger!
> -27 is fortunately still a 1-byte CBOR integer.  Otherwise, we get into 
> 2
> byte CBOR integers and even three byte ones.  Since the delta is 
> relative to
> the enclosing value, not the previous value, we can't even amortize the 
> gap.
> 
> This is an argument to not re-using the values.

Well, that concludes the exercise for me.
Now we can make the examples and fix the cwt-voucher SID allocation

> 
>     > Both can be identified nicely though the presence of 1001030 or 
> 1001000
> 
>     > However, when using comi to return the value of for example:
>     > ietf-voucher/created-on, or
>     > iet-cwt-voucher/created-on
> 
>     > The request for both is identical:
> 
>     > GET //example-server.com/c/1001003
> 
>     > The server does not know which one to return.
>     > Did I miss something?