Re: [Cbor] A CBOR tag for alternatives/unions, request for comments

chrysn <chrysn@fsfe.org> Wed, 23 February 2022 16:10 UTC

Return-Path: <chrysn@fsfe.org>
X-Original-To: cbor@ietfa.amsl.com
Delivered-To: cbor@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8A7263A110D for <cbor@ietfa.amsl.com>; Wed, 23 Feb 2022 08:10:00 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.234
X-Spam-Level:
X-Spam-Status: No, score=-1.234 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_SOFTFAIL=0.665] autolearn=no 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 2UUqJerEd0Uy for <cbor@ietfa.amsl.com>; Wed, 23 Feb 2022 08:09:56 -0800 (PST)
Received: from smtp.akis.at (smtp.akis.at [IPv6:2a02:b18:500:a515::f455]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id ADABB3A1111 for <cbor@ietf.org>; Wed, 23 Feb 2022 08:09:54 -0800 (PST)
Received: from poseidon-mailhub.amsuess.com ([IPv6:2a02:b18:c13b:8010:a800:ff:fede:b1bd]) by smtp.akis.at (8.17.1/8.17.1) with ESMTPS id 21NG9okR039408 (version=TLSv1.2 cipher=ECDHE-ECDSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 23 Feb 2022 17:09:51 +0100 (CET) (envelope-from chrysn@fsfe.org)
X-Authentication-Warning: smtp.akis.at: Host [IPv6:2a02:b18:c13b:8010:a800:ff:fede:b1bd] claimed to be poseidon-mailhub.amsuess.com
Received: from poseidon-mailbox.amsuess.com (hermes.amsuess.com [10.13.13.254]) by poseidon-mailhub.amsuess.com (Postfix) with ESMTP id 19E67D0; Wed, 23 Feb 2022 17:09:50 +0100 (CET)
Received: from hephaistos.amsuess.com (unknown [IPv6:2a02:b18:c13b:8010:eee:cb75:437c:d6a4]) by poseidon-mailbox.amsuess.com (Postfix) with ESMTPSA id B2F07FD; Wed, 23 Feb 2022 17:09:49 +0100 (CET)
Received: (nullmailer pid 831106 invoked by uid 1000); Wed, 23 Feb 2022 16:09:49 -0000
Date: Wed, 23 Feb 2022 17:09:49 +0100
From: chrysn <chrysn@fsfe.org>
To: Carsten Bormann <cabo@tzi.org>
Cc: Michael Peyton Jones <michael.peyton-jones@iohk.io>, Duncan Coutts <duncan@well-typed.com>, cbor@ietf.org, Jared Corduan <jared.corduan@iohk.io>, Alexander Byaly <alexander.byaly@iohk.io>
Message-ID: <YhZcTcCmWVoKNExB@hephaistos.amsuess.com>
References: <CAKoRMYH3MTMi_tX5KHF-O-DTKzopiGqe3fi6XjkPaGCM4823OQ@mail.gmail.com> <7dfd62ccb6c089af90c90f26a8945f23232ecbc1.camel@well-typed.com> <CAKoRMYEOo1Gqfc4W4k3NOLKpFa97Q9YzLCm3r0PJ13V2HJPf3A@mail.gmail.com> <2BBF6463-FDB2-4A8A-B20D-7A1AD976A90D@tzi.org> <CAKoRMYFi8uo2GfHA9s1n+-rMO8Ja9=2qMMzjS9Z=F9r3LFozRQ@mail.gmail.com> <8EA89504-C176-4850-9BB8-C7E7206374FF@tzi.org> <CAKoRMYGmOa0hzEFsJh8kpz0bU5x56Yc9P=DBK-ghU83gXxPv7A@mail.gmail.com> <CAKoRMYGUvmxufQUVyvX2mciq5LCmV0Nz-uE2MJn54GDBB+9DRw@mail.gmail.com> <CAKoRMYF_19V6mu4S9GVqfiNzyQVvvOzX6eYwHp_DtZQoG0xTKg@mail.gmail.com> <4B47F4D7-ADE3-4A22-8A5B-97F4E5FCD933@tzi.org>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="E+X2Ad10vc6frda2"
Content-Disposition: inline
In-Reply-To: <4B47F4D7-ADE3-4A22-8A5B-97F4E5FCD933@tzi.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/cbor/STww26cP6RBu-sWiTgT5_enYg4c>
Subject: Re: [Cbor] A CBOR tag for alternatives/unions, request for comments
X-BeenThere: cbor@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Concise Binary Object Representation \(CBOR\)" <cbor.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/cbor>, <mailto:cbor-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cbor/>
List-Post: <mailto:cbor@ietf.org>
List-Help: <mailto:cbor-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/cbor>, <mailto:cbor-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 23 Feb 2022 16:10:01 -0000

Hello Carsten,

On Wed, Feb 23, 2022 at 02:16:14PM +0100, Carsten Bormann wrote:
> If we have time in the CBOR meeting today (very likely) and you have
> time and comments, we could complete the discussion and ask IANA to
> register.

I think the text should caution the user to say something about the
alternative number stability, maybe extending the Semantics section like
this:

| Protocols that use these tags should consider and document two factors
| that influence an alternative's interpretation:
| 
| * Postion. In some protocols, the meaning of an enumerated alternative
|   will depend on the location in the data item surrounding it. This is
|   especially true of protocols that incorporate other protocols.
| 
| * Stability. Whereas interchange protocols are expected to specify
|   semantics for alternatives in a future-proof way, other use cases
|   (such as debug information or crash recovery) may use alternatives
|   whose meaning is only stable within a software release, or even only
|   for a single build.

BR
Christian

-- 
To use raw power is to make yourself infinitely vulnerable to greater powers.
  -- Bene Gesserit axiom