Re: Connection ID lengths 1, 2 and 3

Mikkel Fahnøe Jørgensen <mikkelfj@gmail.com> Tue, 03 July 2018 13:06 UTC

Return-Path: <mikkelfj@gmail.com>
X-Original-To: quic@ietfa.amsl.com
Delivered-To: quic@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 78669130E0A for <quic@ietfa.amsl.com>; Tue, 3 Jul 2018 06:06:25 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.998
X-Spam-Level:
X-Spam-Status: No, score=-0.998 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FREEMAIL_REPLY=1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, UNPARSEABLE_RELAY=0.001] autolearn=no autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
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 GXvroOVvnkTC for <quic@ietfa.amsl.com>; Tue, 3 Jul 2018 06:06:24 -0700 (PDT)
Received: from mail-io0-x22d.google.com (mail-io0-x22d.google.com [IPv6:2607:f8b0:4001:c06::22d]) (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 80BFF130DF7 for <quic@ietf.org>; Tue, 3 Jul 2018 06:06:24 -0700 (PDT)
Received: by mail-io0-x22d.google.com with SMTP id v26-v6so1638516iog.5 for <quic@ietf.org>; Tue, 03 Jul 2018 06:06:24 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to; bh=aPe1JXgKrIFq7DhafJ9bBYa4fK7N6EMpf9Odzr/r4gM=; b=lLANlRYACr4eU+TU8LMY99MZIG0t83yK3iiuK907rfzMcifkGIQkh+MhdAtc4kUMnb rTWm0DGVwp4ZfxWU9doIWPsM3W3EigVgNUw07/b4UV88Ct+G94xYGnCavNd+gqmSbKt7 t/45dgiXGUc4KP9Rf8J37NZiWmTnMqjU3NYk/zB/8ogWSGRsksieSqLJfJ0fMoeHF6Cj BUqxEO01befFlsJQl5zUO3+H4mPEPDSQv/HVM34ep1khAapXDRwYiJm13oddfWp1S0Qe 6C/qW85Q0XyjMyLyWqGv/YEeDgkWJRgcPDuo8n35PrPSetys30Z3lUkcJFes0QPP7qPJ 2FCw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to; bh=aPe1JXgKrIFq7DhafJ9bBYa4fK7N6EMpf9Odzr/r4gM=; b=DCnsPt6tfNiWw/HuRVDBRHGoaqbUmYViS7iy5HxLMUWytkbIMPnZMlKTAE8Xy61u4s ljJarLqvi5rAV0aTDjJMJvQMtaoyhgFr0LJStdr+KLsmACJxSmDLsbSfc7OmRh0TF/W5 uIZwC9LzvszOcRUSoTQ43q5CuqLbwM5qVXK1bMidVJsEhfEPDzJFIK3SQ/UC6AcHI07w 8VOmbU0LgvsLxw5wR9AcJh5TY/Ki2uk5S2VzxqRtf+r7b6D3a1NxU65XM7Qjo3iu5Sz3 uBuTRuh2tWTj6ITEUGeAIWb9efbx+0BawGwCaPLjsarKMEp5leW0kox0jOIjP/RX1pK7 H3Xw==
X-Gm-Message-State: APt69E06fAiyzgvPMp4Fv5wHssr+UJwZaxpPMEW3qW9dLCRQ4Vm1H8XV wGpDNAaPd46Ys/cr4HgZZx2MFTmpTWwIrKx2z1GnTw==
X-Google-Smtp-Source: AAOMgpfygx5CSWnHb9I3CRoYFkODl31lLm8pkD6CAlba3FnS4bvKHp3giOz1Ol8gKs9G9L1QZHph5m1rWG5tAe9apCQ=
X-Received: by 2002:a6b:1e91:: with SMTP id e139-v6mr25365700ioe.36.1530623183756; Tue, 03 Jul 2018 06:06:23 -0700 (PDT)
Received: from 1058052472880 named unknown by gmailapi.google.com with HTTPREST; Tue, 3 Jul 2018 09:06:22 -0400
From: Mikkel Fahnøe Jørgensen <mikkelfj@gmail.com>
In-Reply-To: <CAOYVs2pZx-u5_Gm0L9oAmztE4p067F34u3+-pyc5ezjm_gquKw@mail.gmail.com>
References: <CAOYVs2pZx-u5_Gm0L9oAmztE4p067F34u3+-pyc5ezjm_gquKw@mail.gmail.com>
X-Mailer: Airmail (420)
MIME-Version: 1.0
Date: Tue, 03 Jul 2018 09:06:22 -0400
Message-ID: <CAN1APdeRzJHEPH0etK1g6qWDwyemnuaU+6G5RrdNZj67oouA+w@mail.gmail.com>
Subject: Re: Connection ID lengths 1, 2 and 3
To: QUIC WG <quic@ietf.org>, Marten Seemann <martenseemann@gmail.com>
Content-Type: multipart/alternative; boundary="000000000000272afc057017fb22"
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic/Oxw2Ncqy9kL7y-nmC9h573X3Gjs>
X-BeenThere: quic@ietf.org
X-Mailman-Version: 2.1.26
Precedence: list
List-Id: Main mailing list of the IETF QUIC working group <quic.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/quic>, <mailto:quic-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/quic/>
List-Post: <mailto:quic@ietf.org>
List-Help: <mailto:quic-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/quic>, <mailto:quic-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 03 Jul 2018 13:06:26 -0000

That is correct. Especially in low-power sensor mesh networks.


On 3 July 2018 at 14.45.30, Marten Seemann (martenseemann@gmail.com) wrote:

First of all, I realise that I'm bringing this up late in the process, and
maybe too late, since this would require a change to the invariants.

The connection IDs can be either 0 bytes or anything between 4 and 18 bytes
(inclusive). Lengths of 1, 2 and 3 bytes are not possible.
For p2p applications, and for server deployments that are not doing
connection ID based load balancing, it would be interesting to use shorter
connection IDs. One might imagine that a peer encodes the length of the
connection ID into the first few bits, and then starts using 1 byte
connection IDs first, and successively moves to longer lengths only when
handling more connections. A p2p host handling several thousand
simultaneous connections (which will be enough for many p2p protocols)
would never have to use anything longer than 2 byte connection IDs.

In the connection ID length field in the Long Header, we only have to 4 bit
to encode a range of 19 values (we want 0 byte connection IDs, and we want
to support 18 byte connection IDs), so *some* values have to be left out.
However, leaving out 1, 2 and 3 seems a bit unfortunate, as there will be
more use cases for these values than e.g. for 13, 14 and 15 bytes.