Re: HTTP/2 Upgrade with content?

Cory Benfield <cory@lukasa.co.uk> Fri, 13 March 2015 08:57 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ietf.org@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id DF9CD1A1B12 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Fri, 13 Mar 2015 01:57:20 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.29
X-Spam-Level:
X-Spam-Status: No, score=-6.29 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, FM_FORGED_GMAIL=0.622, RCVD_IN_DNSWL_HI=-5, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=ham
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 IKO0KfJs9888 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Fri, 13 Mar 2015 01:57:19 -0700 (PDT)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 2DE3E1A003B for <httpbisa-archive-bis2Juki@lists.ietf.org>; Fri, 13 Mar 2015 01:57:19 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.80) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1YWLLm-0007Gj-A7 for ietf-http-wg-dist@listhub.w3.org; Fri, 13 Mar 2015 08:53:46 +0000
Resent-Date: Fri, 13 Mar 2015 08:53:46 +0000
Resent-Message-Id: <E1YWLLm-0007Gj-A7@frink.w3.org>
Received: from maggie.w3.org ([128.30.52.39]) by frink.w3.org with esmtp (Exim 4.80) (envelope-from <cory@lukasa.co.uk>) id 1YWLLg-0007AO-H8 for ietf-http-wg@listhub.w3.org; Fri, 13 Mar 2015 08:53:40 +0000
Received: from mail-la0-f44.google.com ([209.85.215.44]) by maggie.w3.org with esmtps (TLS1.0:RSA_ARCFOUR_SHA1:16) (Exim 4.72) (envelope-from <cory@lukasa.co.uk>) id 1YWLLe-0005EH-EY for ietf-http-wg@w3.org; Fri, 13 Mar 2015 08:53:40 +0000
Received: by labgd6 with SMTP id gd6so21091893lab.6 for <ietf-http-wg@w3.org>; Fri, 13 Mar 2015 01:53:11 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=m2MmV5OzVzaHmpjPeVcRvQCZcz3x0ABc3rqmRl2zXSU=; b=M01Zduc/1vsJRNL0nfiybByvfgKoaHiR5b27V3AY9gdoBIxC9uwk+YFQssj1/bPZeG xOXbIZVzkGytPdY7or3dvA6isNOQCQfGX9/Rr2XO0oNjZcOOxjq2LPhkhZMrfICL+G0U gMbctwjUWLZB1eItBYMq8g8rtRWiuKCmkCAa+VZRLL8NANlqIOLd1N1JxHbjD8z8uVYa yW3NsDEd2Mm9dqq8VNeyfyMWfzGCzP/mP41IdnwOSfM4TFQW40CuhRTL7ulgmZfw4KBw vWD3k35YShaCqVZ0PPNAZDdFuxd9p7SlBiU2KmVq9OZ+QEZB5AxtqGFgUCjA/kl3pfb1 HHlg==
X-Gm-Message-State: ALoCoQmYqpbQ5dX438wFzustzkZgo52WWYc3XqVvchtEJemWLa264x6UGT+HDYlkYhm0oj9x5ksO
MIME-Version: 1.0
X-Received: by 10.152.116.65 with SMTP id ju1mr22407405lab.32.1426236791254; Fri, 13 Mar 2015 01:53:11 -0700 (PDT)
Received: by 10.25.155.129 with HTTP; Fri, 13 Mar 2015 01:53:11 -0700 (PDT)
X-Originating-IP: [192.91.191.162]
In-Reply-To: <alpine.DEB.2.11.1503130833190.13706@tvnag.unkk.fr>
References: <CAH_y2NF3iwND1ttQDY98KC_u=OZj5aqEABmXHKObMgqPH1npLg@mail.gmail.com> <BL2PR03MB1323474B977B051738AD09187060@BL2PR03MB132.namprd03.prod.outlook.com> <CAH_y2NFV=Z7hqbtWTdiePRwUnhhRjiP8R_Ua7kmpZEkwXtxgEA@mail.gmail.com> <B5C01B7A-9215-4268-B189-E6281F425BF7@greenbytes.de> <alpine.DEB.2.11.1503130833190.13706@tvnag.unkk.fr>
Date: Fri, 13 Mar 2015 08:53:11 +0000
Message-ID: <CAH_hAJE2XgJSdvgxfzGfQHSOw4XjrbboEmGp1-GFPjJD=8dMiw@mail.gmail.com>
From: Cory Benfield <cory@lukasa.co.uk>
To: Daniel Stenberg <daniel@haxx.se>
Cc: Stefan Eissing <stefan.eissing@greenbytes.de>, Greg Wilkins <gregw@intalio.com>, Mike Bishop <Michael.Bishop@microsoft.com>, HTTP Working Group <ietf-http-wg@w3.org>
Content-Type: text/plain; charset="UTF-8"
Received-SPF: pass client-ip=209.85.215.44; envelope-from=cory@lukasa.co.uk; helo=mail-la0-f44.google.com
X-W3C-Hub-Spam-Status: No, score=-3.5
X-W3C-Hub-Spam-Report: AWL=-2.768, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001, URIBL_BLOCKED=0.001
X-W3C-Scan-Sig: maggie.w3.org 1YWLLe-0005EH-EY 8c49bd6eeaac6bc1e8e129107aaaefa5
X-Original-To: ietf-http-wg@w3.org
Subject: Re: HTTP/2 Upgrade with content?
Archived-At: <http://www.w3.org/mid/CAH_hAJE2XgJSdvgxfzGfQHSOw4XjrbboEmGp1-GFPjJD=8dMiw@mail.gmail.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/28952
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <http://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>

On 13 March 2015 at 07:40, Daniel Stenberg <daniel@haxx.se> wrote:

> Not accepting a POST immediately will be surprising to users. There are
> quite a few users in the wild today that run curl like this:
>
>  $ curl -d lotsofdata [URL]
>
> which thus sends a POST immediately with that data over HTTP/1.1, and the
> same thing for HTTP/2 is almost identical, just adding asking for http2:
>
>  $ curl --http2 -d lotsofdata [URL]
>
> which will make a POST with an Upgrade: h2c header and Expect: 100-continue.
>
> If a server then suddenly doesn't handle the POST + upgrade it puts a rather
> arbitrary (from the client's perspective) block on when a client can or
> cannot switch to HTTP/2 on such a server.

Agreed from hyper's perspective as well.

We can always add logic to only send HTTP upgrade headers on requests
without bodies, but it feels like a weird restriction.