RE: [Editorial Errata Reported] RFC7540 (4871)

Mike Bishop <> Wed, 30 November 2016 19:18 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id D8426129971 for <>; Wed, 30 Nov 2016 11:18:12 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -9.896
X-Spam-Status: No, score=-9.896 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, RP_MATCHES_RCVD=-2.896, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (1024-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id e1N3e-SKev2w for <>; Wed, 30 Nov 2016 11:18:10 -0800 (PST)
Received: from ( []) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id EDB231298CA for <>; Wed, 30 Nov 2016 11:18:09 -0800 (PST)
Received: from lists by with local (Exim 4.80) (envelope-from <>) id 1cCAKY-0000zF-65 for; Wed, 30 Nov 2016 19:14:10 +0000
Resent-Date: Wed, 30 Nov 2016 19:14:10 +0000
Resent-Message-Id: <>
Received: from ([]) by with esmtps (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from <>) id 1cCAKL-0000xL-KL for; Wed, 30 Nov 2016 19:13:57 +0000
Received: from ([] by with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from <>) id 1cCAKC-0005Ia-Oy for; Wed, 30 Nov 2016 19:13:52 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=BtYkc7YKV15cZ5culCK3y1jnGjXxduY9+b9bb4mgj/E=; b=Onaazg9CW++GIC/f/ShoVYBCBgKByHaBBepvOVGyrpPkguvDT5nhZkMd87SGsrhumITUImJNonOOZxHnS7QSn5Ijxmi2YVR4YH4qgA8DPKRqk9l6jPztqUmJz33b5KA2smKL9k65/5WuXqslTCb61dqYyxPw0Io+ZH+p5RQw6sA=
Received: from ( by ( with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.747.13; Wed, 30 Nov 2016 18:58:32 +0000
Received: from ([]) by ([]) with mapi id 15.01.0747.018; Wed, 30 Nov 2016 18:58:32 +0000
From: Mike Bishop <>
To: laike9m <>, Stefan Eissing <>
CC: "" <>, Kazuho Oku <>, Cory Benfield <>, Martin Thomson <>, RFC Errata System <>, Mike Belshe <>, Roberto Peon <>, Ben Campbell <>, Alissa Cooper <>, Alexey Melnikov <>, Patrick McManus <>, Mark Nottingham <>, HTTP Working Group <>
Thread-Topic: [Editorial Errata Reported] RFC7540 (4871)
Date: Wed, 30 Nov 2016 18:58:31 +0000
Message-ID: <>
References: <> <> <> <> <> <> <> <> <> <>
In-Reply-To: <>
Accept-Language: en-US
Content-Language: en-US
authentication-results: spf=none (sender IP is );
x-originating-ip: [2001:4898:80e8:c::14c]
x-ms-office365-filtering-correlation-id: b93c268d-755a-4eda-b565-08d41952e124
x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001);SRVR:BN6PR03MB2706;
x-microsoft-exchange-diagnostics: 1; BN6PR03MB2706; 7:BTUVrSgOokvIijStXbEaCnmMAZ59Hw9TmxkF11HhxaxZeNb69mY4Ny4CkS0LhqMC0f04tSxpnpODAs/dQDH4JQaYnBlwScW3qyKkphRA8wDTUyRQ+4UdxCnyxN1PikrFV9jqszBtmRdB4ZHSw4xUrt5ic/zFeyW/DE11kZhfcffJ5RsFAXiyQXdEACV4GWT3nxuPguIRP0Haqjpdcwtc8gqwd3mgjXZvzH1jAvcZ/Ct8hJIMt82Zv7Q5Hj6ErW+AJ5AWcvEhUE7pwj8Lg8c7vLZ8rtbJpbyxGez6ujrZuk469QhStGfHxBlegNpvnou4GLhFnOh9xbrz74llUmKLePpCVQ+b2PcXisReZNrg1VOHyU/RXHVQa+lXdmhXJT0Tq1aW+vTdhTKHudTnsudiVgXYe2VFvGAeCOu9O65/EZ8oxM72kGGXSXZg/cKY2Y1EwuuS35aSXXJH3qGeCFAz6HHuoZnz/CtM5BOiZn3SG5E=
x-microsoft-antispam-prvs: <>
x-exchange-antispam-report-test: UriScan:(166708455590820)(211936372134217)(21748063052155)(21532816269658)(17755550239193);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(61425038)(6040375)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046)(6055026)(61426038)(61427038)(6041248)(20161123560025)(20161123555025)(20161123564025)(20161123562025)(6047074)(6072148); SRVR:BN6PR03MB2706; BCL:0; PCL:0; RULEID:; SRVR:BN6PR03MB2706;
x-forefront-prvs: 0142F22657
x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(979002)(7916002)(24454002)(199003)(189002)(377454003)(377424004)(2906002)(97736004)(101416001)(4326007)(2950100002)(86612001)(2900100001)(86362001)(4001150100001)(6116002)(5001770100001)(68736007)(102836003)(93886004)(790700001)(106116001)(105586002)(9686002)(99286002)(81166006)(7416002)(8936002)(81156014)(106356001)(33656002)(6506003)(606004)(38730400001)(5660300001)(3660700001)(76576001)(8990500004)(8676002)(19609705001)(8666005)(10290500002)(5005710100001)(122556002)(7696004)(189998001)(39060400001)(74316002)(39410400001)(7736002)(77096006)(92566002)(3280700002)(50986999)(229853002)(39450400002)(10090500001)(7846002)(345774005)(7906003)(54356999)(76176999)(7059030)(969003)(989001)(999001)(1009001)(1019001); DIR:OUT; SFP:1102; SCL:1; SRVR:BN6PR03MB2706;; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en;
received-spf: None ( does not designate permitted sender hosts)
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: multipart/alternative; boundary="_000_BN6PR03MB2708DD14E2914CD194D711B4878C0BN6PR03MB2708namp_"
MIME-Version: 1.0
X-MS-Exchange-CrossTenant-originalarrivaltime: 30 Nov 2016 18:58:31.9022 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR03MB2706
Received-SPF: pass client-ip=;;
X-W3C-Hub-Spam-Status: No, score=-3.9
X-W3C-Hub-Spam-Report: AWL=-2.423, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, W3C_NW=0.5
X-W3C-Scan-Sig: 1cCAKC-0005Ia-Oy facbead9cc8ec19ad0f109aad127938a
Subject: RE: [Editorial Errata Reported] RFC7540 (4871)
Archived-At: <>
X-Mailing-List: <> archive/latest/33051
Precedence: list
List-Id: <>
List-Help: <>
List-Post: <>
List-Unsubscribe: <>

And I think you’ve hit on half the controversy here:  wording.  From a non-graph-theory point of view, I read “neighbors” as “other nodes with a common parent.”  So the wording here may imply different things to different people.

I think of it as a recursive allocation – given a tree rooted at X and resources Y to allocate to it:

  *   Define Unblocked(N) true if N or any descendant of N can make progress
  *   If Unblocked(X) is false, allocate no capacity
  *   If X able to make progress, allocate Y to X; return
  *   Else
     *   Let C = count of children of X where Unblocked(child) is true
     *   Repeat algorithm allocating Y / C to the subtree rooted at each (unblocked) child of X

If I’m correct (always chancey), the other issue is that this text talks about redistributing if X is blocked, not if X and all descendants of X are blocked.  That’s addressed elsewhere, but not clearly stated in this particular instance.

From: laike9m []
Sent: Wednesday, November 30, 2016 7:57 AM
To: Stefan Eissing <>
Cc:; Kazuho Oku <>; Cory Benfield <>; Martin Thomson <>; RFC Errata System <>; Mike Belshe <>; Roberto Peon <>; Ben Campbell <>; Alissa Cooper <>; Alexey Melnikov <>; Patrick McManus <>; Mark Nottingham <>; HTTP Working Group <>
Subject: Re: [Editorial Errata Reported] RFC7540 (4871)

Since it’s me that brought this question<> to Martin, I also got some thoughts on it(from a reader's perspective):

Basically the question is not about the example being wrong, it’s about the above description being contradictory with the example.

…Resources are shared between streams with the same parent stream, which means that if a stream in that set closes or becomes blocked, any spare capacity allocated to a stream is distributed to the immediate neighbors of the stream. However, if the common dependency is removed from the tree, those streams share resources with streams at the next highest level.

So, let’s assume the example is correct, then there are three problems with this paragraph.
1.       “in that set”: “set” here apparently means “streams with the same parent stream”, so emphasizing “in that set” makes readers feel the resource reallocation process is between those streams. Better remove it.
2.       “neighbors”: it’s true that in graph theory “neighbors” means nodes that directly connect to a specific node(like C, D to A), but since we’re talking about a tree, if we could use more precise words like “dependent streams” or “child streams”, then there would be no controversy. I searched the whole RFC, “neighbor” is only used once, which does cause some confusion.
3.       “However, if the common dependency is removed from the tree, those streams share resources with streams at the next highest level.”: this whole sentence, in such case, is not even necessary.

So the modified version would be something like this:

Resources are shared between streams with the same parent stream, which means that if a stream closes or becomes blocked, any spare capacity allocated to the stream is distributed to the dependent streams of it.

But yeah, like Cory said, Martin definitely proposed the erratum for a reason, and it's still possible the erratum is what the RFC writers really meant.

On Wed, Nov 30, 2016 at 10:54 PM, Stefan Eissing <<>> wrote:
A stream is blocked only by flow-control, as I read it. The errata would suggest that the flow control of the parent would effectively rule those of its descendants? That does not make much sense to me.

This could easily become very messy. If flow control of dependant nodes become entangled with their ancestors, then we basically have nested flow control windows? Please. no.


> Am 30.11.2016 um 14:49 schrieb Tatsuhiro Tsujikawa <<>>:
> On Wed, Nov 30, 2016 at 10:29 PM, Kazuho Oku <<>> wrote:
> 2016-11-30 22:05 GMT+09:00 Cory Benfield <<>>:
> >
> >
> > On 30 Nov 2016, at 13:04, Kazuho Oku <<>> wrote:
> >
> > My understanding is that you do not need to distinguish between completed, idle and blocked states.
> >
> > For a stream under either of the three states, the weight associated to the stream is distributed to the dependents.
> >
> > That is what nghttp2 does and H2O does (except for the fact that it does not remember closed streams), and I this behavior is what is suggested by the spec.
> >
> >
> > My understanding of what Martin is suggesting is that that isn’t true: blocked streams do not distribute their weight to their dependants.
> Thank you for pointing that out.
> My understanding is that there is no special casing for blocked
> streams. Section 5.3.1 handles all the states we are discussing
> equally, quote:
>    Inside the dependency tree, a dependent stream SHOULD only be
>    allocated resources if either all of the streams that it depends on
>    (the chain of parent streams up to 0x0) are closed or it is not
>    possible to make progress on them.
> I also do not see why it would be beneficial to treat them differently.
> ​I agree with Kazuho.  I think RFC 7540 is written based on the idea that dependent stream ca​n receive resource if the streams between it and root are all either in closed, idle or blocked.
> Actually, from nghttp2 commit log, I made a commit which implemented the proposed  text.  But we later reverted it, since there is no text in the draft at that time to mandate that behaviour.
> Best regards,
> Tatsuhiro Tsujikawa
> >
> > However, that’s also what the Python Priority implementation does.
> >
> > Cory
> >
> --
> Kazuho Oku