RE: GOAWAY clarification

Mike Bishop <> Mon, 23 March 2015 00:22 UTC

Return-Path: <>
Received: from localhost ( []) by (Postfix) with ESMTP id A148C1A871F for <>; Sun, 22 Mar 2015 17:22:54 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -6.912
X-Spam-Status: No, score=-6.912 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=ham
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id rt5XiNQWKvvs for <>; Sun, 22 Mar 2015 17:22:52 -0700 (PDT)
Received: from ( []) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 867B61A871C for <>; Sun, 22 Mar 2015 17:22:52 -0700 (PDT)
Received: from lists by with local (Exim 4.80) (envelope-from <>) id 1YZq43-0005z5-1w for; Mon, 23 Mar 2015 00:17:55 +0000
Resent-Date: Mon, 23 Mar 2015 00:17:55 +0000
Resent-Message-Id: <>
Received: from ([]) by with esmtp (Exim 4.80) (envelope-from <>) id 1YZq3q-0005xd-HU for; Mon, 23 Mar 2015 00:17:42 +0000
Received: from ([] by with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from <>) id 1YZq3p-00060d-Ix for; Mon, 23 Mar 2015 00:17:42 +0000
Received: from ( by ( with Microsoft SMTP Server (TLS) id; Mon, 23 Mar 2015 00:17:13 +0000
Received: from ([]) by ([]) with mapi id 15.01.0106.007; Mon, 23 Mar 2015 00:17:13 +0000
From: Mike Bishop <>
To: Martin Thomson <>, HTTP Working Group <>
Thread-Topic: GOAWAY clarification
Date: Mon, 23 Mar 2015 00:17:13 +0000
Message-ID: <>
References: <> <> <> <> <> <>
In-Reply-To: <>
Accept-Language: en-US
Content-Language: en-US
x-originating-ip: [2601:8:9680:45e:5c34:da45:1f3a:c00f]
authentication-results:; dkim=none (message not signed) header.d=none;
x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BL2PR03MB131;
x-microsoft-antispam-prvs: <>
x-forefront-antispam-report: BMV:1; SFV:NSPM; SFS:(10019020)(6009001)(377454003)(51704005)(33656002)(221733001)(77156002)(62966003)(50986999)(76176999)(54356999)(561944003)(76576001)(19580395003)(2950100001)(46102003)(19580405001)(122556002)(99286002)(107886001)(87936001)(74316001)(15975445007)(86362001)(92566002)(102836002)(106116001)(2656002)(86612001)(40100003)(3826002); DIR:OUT; SFP:1102; SCL:1; SRVR:BL2PR03MB131;; FPR:; SPF:None; MLV:sfv; LANG:en;
x-exchange-antispam-report-test: UriScan:;
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(601004)(5005006)(5002010); SRVR:BL2PR03MB131; BCL:0; PCL:0; RULEID:; SRVR:BL2PR03MB131;
x-forefront-prvs: 05245CA661
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-MS-Exchange-CrossTenant-originalarrivaltime: 23 Mar 2015 00:17:13.3773 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL2PR03MB131
Received-SPF: pass client-ip=;;
X-W3C-Hub-Spam-Status: No, score=-3.0
X-W3C-Hub-Spam-Report: AWL=-3.949, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, W3C_NOWL=1
X-W3C-Scan-Sig: 1YZq3p-00060d-Ix 069c8888e7e0eac172f375c882cb1d98
Subject: RE: GOAWAY clarification
Archived-At: <>
X-Mailing-List: <> archive/latest/29012
Precedence: list
List-Id: <>
List-Help: <>
List-Post: <>
List-Unsubscribe: <>

I'm fine with the clarification that the sender of GOAWAY may have initiated streams with a higher stream ID than the recipient of GOAWAY, and the "will ignore" only applies to the recipient-initiated streams.  I think that was always implicit, and I'm happy to make it explicit.

On the other hand, I'm still inclined to see MUST NOT create new streams as the intent of GOAWAY.  The two-phase approach was introduced as an allowance for streams the client may have already initiated, but the client still MUST stop initiating upon receipt of the GOAWAY.  Now, the reality is that the server can't actually tell for sure when the client stopped initiating new streams, so a non-compliant client could keep initiating up to the number that was actually in the GOAWAY frame and hope the server doesn't catch it.  This change just makes that particular misbehavior permitted, which doesn't seem like a net improvement to me.  If the server told the client to stop, the client should stop.

I don't think that's in contradiction to the guidance below, since the first GOAWAY tells the client to stop initiating, and the second GOAWAY confirms the last already-in-flight stream that the server chose to service.  I had not understood the two-phase approach to intend the client to keep sending while it spun up the second connection, and so didn't see the text as inconsistent in that regard.  It sounds like others interpreted the first GOAWAY as a hint that a "real" GOAWAY would follow later, but multiple are allowed.  How does the client know it's finally got the "real" GOAWAY that it needs to obey?

-----Original Message-----
From: Martin Thomson [] 
Sent: Sunday, March 22, 2015 9:19 AM
To: HTTP Working Group
Subject: Re: GOAWAY clarification

...and I've drawn some pictures:

On consideration, this is a technical change, albeit one that arises out of clarifying what was previously ambiguous.  I will take the advice of the working group on how to proceed.

On 22 March 2015 at 08:51, Martin Thomson <> wrote:
> After sleeping on it, I have taken a more thorough look at the section 
> and noted a few other inconsistencies.  Thus, I've made a second 
> proposal that is a little more thorough:
> One note regarding this text, since this has already come up on github...
> This shouldn't change behaviour.  If you have an implementation that 
> sends GOAWAY based on the stream identifiers you have seen, then you 
> are exposed to the "bug" in issue #458, but are otherwise unaffected.
> If you implemented the graceful shutdown based on the text produced 
> for #458; that is, you send two GOAWAY frames, then the only 
> consequence is that streams might have to be retried by the client.
> Ultimately, the choice of last-stream-id will determine how much 
> allowance is made for imminent transactions.
> On 21 March 2015 at 19:27, Martin Thomson <> wrote:
>> On 21 March 2015 at 09:35, Martin Thomson <> wrote:
>>> It would be easy to deal with your concern by having the receiver of 
>>> the GOAWAY reply with their own.  I think that avoids all of the 
>>> problems you indicate.
>> So @Scottmitch also notes a further bug here.  We currently prohibit 
>> the creation of more streams after GOAWAY, which is in direct 
>> contradiction to the graceful shutdown process.
>>     Receivers of a GOAWAY frame MUST NOT open additional
>>     streams on the connection, although a new connection can be
>>     established for new streams.
>> That contradicts the guidance we provide later in the section 
>> regarding graceful shutdown.  It prevents a seamless transition from 
>> one connection to another.
>> I've created a PR for this.  
>> I've also taken the liberty of taking a variation on the text from @buchgr.
>> I think that this is erratum-worthy, so I'd like to get this in.  But 
>> I won't do so if there are objections.  If my answer to Amos'
>> objection didn't satisfy you (see above; see also the PR text; Amos?) 
>> then I can remove the second part of the change, but I tend to think 
>> that it's more consistent with the other fix.