new draft: RELIABLE_RESET_STREAM

Marten Seemann <martenseemann@gmail.com> Fri, 09 September 2022 08:34 UTC

Return-Path: <martenseemann@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 D5CBBC14CF13 for <quic@ietfa.amsl.com>; Fri, 9 Sep 2022 01:34:43 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.103
X-Spam-Level:
X-Spam-Status: No, score=-2.103 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_BLOCKED=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=unavailable autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IkADrGeZW411 for <quic@ietfa.amsl.com>; Fri, 9 Sep 2022 01:34:43 -0700 (PDT)
Received: from mail-ej1-x630.google.com (mail-ej1-x630.google.com [IPv6:2a00:1450:4864:20::630]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id F351FC1522D6 for <quic@ietf.org>; Fri, 9 Sep 2022 01:28:55 -0700 (PDT)
Received: by mail-ej1-x630.google.com with SMTP id r17so2276672ejy.9 for <quic@ietf.org>; Fri, 09 Sep 2022 01:28:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date; bh=RW7/fYptdOTnc1CW4oWZVpty3I6h0ZazZuwbZGzFF8k=; b=Urhy2kTYFKzXH8p56irHtZvEx1pmT5ojZqrA/gcoCVl7VWtzy7irWBub6DLRBVHy4b CSDLldG+cnwra08XpRD313VALUe7dt39xcC2ft5HJ6GGB1HLUu3sprBq3zobiae/o3Kg jeihRTSlnHHeyf1cEc9IVXqw9phLnsqoEOglEuCk//Ou1hUjJFMnKAd4is1O+6ATTy4q gXJhgoka8//HDMzEWakgi3G4/uRO7RN5mM7dSghHiorx/anz/WmtqPW2a3dL7s03K7e2 a/1gWaF4L2N6JdesT3ZM5w9CJd8M3nGDzeTWlvgNzLOZ9BH28zInezLSULhUFM2Avqc4 qDzQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date; bh=RW7/fYptdOTnc1CW4oWZVpty3I6h0ZazZuwbZGzFF8k=; b=P++zFBR7C/wSOSqQU0P6yr4PzgnvYLs9RHEUV5P7gI9VDKg4uvH7/ppWGS1lyzlZ2B cOmXuIqbGmmg3XpWUFgMdmZ/6hzN7OrgJjZVDq8TV1479bt4xeJu1gnWkDwO42Hr6Gxg rzZ+hJbe/9bV8D9/yNhcLfsvZGrKxxE39UraOKfFObDEDXcvp8Vy9ijNeFY9bm9A2dlj YpyvMRsiKdc0LUpt286C7G49ueFg9btZgf4Z3juGjzWfheMTsYr+wojP2wycmSknWozD J2fCcbqljeurkD6x21oLYWFMbKjy/ptcZEkSFSLG1Z4vPBL+HwZy5x93Eqtrt1wmGYvx g5YA==
X-Gm-Message-State: ACgBeo2QxUaA68lRqU/b9dOHHanHHkAgM73vTPNi1uQPjuEvjCtrJiIg jQJx35ilHUEy8HlPNvsIBIGf9sVRsxSQHbEwphfQsdWUvk2Wffcv
X-Google-Smtp-Source: AA6agR7ic5OcBuDhR1ckZ+boZsOBafrh+UGokdAh1cZbuJ6yg0Cf/zIfuRxZOQeTGvtyQz3DuJwHny7Dy+2WY6kog/c=
X-Received: by 2002:a17:906:794f:b0:770:88ad:a5de with SMTP id l15-20020a170906794f00b0077088ada5demr7476617ejo.503.1662712133537; Fri, 09 Sep 2022 01:28:53 -0700 (PDT)
MIME-Version: 1.0
From: Marten Seemann <martenseemann@gmail.com>
Date: Fri, 09 Sep 2022 11:28:41 +0300
Message-ID: <CAOYVs2rQWUbd02jz7ywDi1xcx30wD1PSf-GRi3ZrPmGnXouy2A@mail.gmail.com>
Subject: new draft: RELIABLE_RESET_STREAM
To: QUIC WG <quic@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000015551b05e83a56b4"
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic/xyM4siVB3aIp0kUCevyFYseUhQQ>
X-BeenThere: quic@ietf.org
X-Mailman-Version: 2.1.39
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: Fri, 09 Sep 2022 08:34:43 -0000

In RFC 9000 we defined a RESET_STREAM frame. When a stream is reset, the
receiver may deliver the reset error to the application immediately. On the
sender side, lost STREAM frames won't be retransmitted.
When building applications on top of QUIC, it is a common pattern to send
some kind of identifier (an ID or a string, for example) first, to allow
the application to route the stream to a subpart of that application. For
example, WebTransport sends the Session ID of the WebTransport Session.
Outside of the IETF, I've used something similar for layering various
applications on top of QUIC.

When a stream is reset, the receiver might end up unable to associate the
stream with the respective subpart of the application. This is problematic,
since

   1. depending on the application protocol, a reset of a stream might
   carry application-layer semantics, and
   2. the RESET_STREAM only closes one side of the stream, and it might
   depend on the (sub-) application how the other direction of the stream is
   handled

This problem is not unique to WebTransport, but occurs for every
application using some kind of stream identifier. It might make sense to
design a solution at the QUIC layer.

I've just submitted a draft that aims to solve this problem:
https://datatracker.ietf.org/doc/draft-seemann-quic-reliable-stream-reset/
It defines a RELIABLE_RESET_STREAM frame, which is essentially
a RESET_STREAM frame with one additional field, the Reliable Size. The
sender of the RELIALBE_RESET_STREAM frame commits to (re-)transmitting
stream data up to the Reliable Size reliably, and the receiver delivers
data up to that offset to the application before surfacing the reset error.
In WebTransport, you'd set the Reliable Size such that it covers everything
up the Session ID, thereby making sure that any stream can always be routed
to its WebTransport session.

Obviously, there are use cases for this draft beyond the reliable
transmission of just a stream identifier. One could imagine an application
protocol that would benefit from being able to have the first part of an
actual application-layer message being delivered reliably. I'm happy about
enabling those use cases, but I've avoided making this draft more
complicated than necessary by accommodating the more general cases.