Re: H2 Implementation Debug State URI

Stefan Eissing <stefan.eissing@greenbytes.de> Thu, 28 July 2016 14:04 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@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 (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id B813612D58E for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Thu, 28 Jul 2016 07:04:56 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -8.308
X-Spam-Level:
X-Spam-Status: No, score=-8.308 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, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-1.287, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=greenbytes.de header.b=ql/kz/Pp; dkim=pass (1024-bit key) header.d=greenbytes.de header.b=GAmOQS0j
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 eF5Uoh4Rxl6w for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Thu, 28 Jul 2016 07:04:53 -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 BA92B12D0AD for <httpbisa-archive-bis2Juki@lists.ietf.org>; Thu, 28 Jul 2016 07:04:53 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.80) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1bSlrv-0002F7-Qe for ietf-http-wg-dist@listhub.w3.org; Thu, 28 Jul 2016 14:00:59 +0000
Resent-Date: Thu, 28 Jul 2016 14:00:59 +0000
Resent-Message-Id: <E1bSlrv-0002F7-Qe@frink.w3.org>
Received: from lisa.w3.org ([128.30.52.41]) by frink.w3.org with esmtps (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from <stefan.eissing@greenbytes.de>) id 1bSlrt-0002Dk-87 for ietf-http-wg@listhub.w3.org; Thu, 28 Jul 2016 14:00:57 +0000
Received: from mail.greenbytes.de ([5.10.171.186]) by lisa.w3.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from <stefan.eissing@greenbytes.de>) id 1bSlrp-0006I3-6I for ietf-http-wg@w3.org; Thu, 28 Jul 2016 14:00:54 +0000
Received: by mail.greenbytes.de (Postfix, from userid 117) id AB9B815A047E; Thu, 28 Jul 2016 16:00:24 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=greenbytes.de; s=mail; t=1469714424; bh=UVks4GixG7hH+xYqkep87elW8eef8OI7PO+h1MEKJ1U=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=ql/kz/PpmkAmeTMnAnxClYAsGVmxmYCK1fbK66fzFQGNphtN6imD4FZ8jXYG0A4EA eN6tVnH+SvLCHddOpIZ43xZBwITBtxB6kF/apULzvrikK3yXl+4USfjBeeVh6QScfI mWsEECmAmbgiJKRU4sWxgSzajmSYn7Fy6Dna9h7U=
Received: from [192.168.1.42] (unknown [192.168.1.1]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mail.greenbytes.de (Postfix) with ESMTPSA id 9E19315A047E; Thu, 28 Jul 2016 16:00:22 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=greenbytes.de; s=mail; t=1469714422; bh=UVks4GixG7hH+xYqkep87elW8eef8OI7PO+h1MEKJ1U=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=GAmOQS0jBTKffeLunA7/ZE84Y2VCboykIgPIVAWZ1zIiXOYj/9A7Up4FK2pFdPAyo 8p1HI7bU0t8FzADPs3Hdrj6uA9WCpMNvDuRtzpikUrSZHy+qHquygv5VyRm6FAeF6m Xh2bBdYFdXanCjSA7Pxt1bGm3rHdMhGKdQwBbCN0=
Content-Type: text/plain; charset="utf-8"
Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\))
From: Stefan Eissing <stefan.eissing@greenbytes.de>
In-Reply-To: <63CCB07A-0204-4CF7-B598-9497D7112021@lukasa.co.uk>
Date: Thu, 28 Jul 2016 16:00:22 +0200
Cc: HTTP Working Group <ietf-http-wg@w3.org>
Content-Transfer-Encoding: quoted-printable
Message-Id: <3254E485-1719-4561-AA64-C003C81468A5@greenbytes.de>
References: <63CCB07A-0204-4CF7-B598-9497D7112021@lukasa.co.uk>
To: Cory Benfield <cory@lukasa.co.uk>
X-Mailer: Apple Mail (2.3124)
Received-SPF: pass client-ip=5.10.171.186; envelope-from=stefan.eissing@greenbytes.de; helo=mail.greenbytes.de
X-W3C-Hub-Spam-Status: No, score=-5.8
X-W3C-Hub-Spam-Report: AWL=-0.491, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RP_MATCHES_RCVD=-1.287, SPF_PASS=-0.001, W3C_AA=-1, W3C_WL=-1
X-W3C-Scan-Sig: lisa.w3.org 1bSlrp-0006I3-6I f672e3644112aff638df10ded893121d
X-Original-To: ietf-http-wg@w3.org
Subject: Re: H2 Implementation Debug State URI
Archived-At: <http://www.w3.org/mid/3254E485-1719-4561-AA64-C003C81468A5@greenbytes.de>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/32068
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>

Thanks, Cory!. Apache will offer this as a configurable handler and I will make a beta available via github soon. Currently outputs lacks individual streams and looks like this:
{
  "settings": {
    "SETTINGS_MAX_CONCURRENT_STREAMS": 100,
    "SETTINGS_MAX_FRAME_SIZE": 16384,
    "SETTINGS_INITIAL_WINDOW_SIZE": 65535,
    "SETTINGS_ENABLE_PUSH": 1
  },
  "connFlowIn": 2147483647,
  "connFlowOut": 12571993,
  "sentGoAway": 0,
  "in": {
    "requests": 63,
    "resets": 0, 
    "frames": 134,
    "octets": 3831
  },
  "out": {
    "responses": 62,
    "frames": 130,
    "octets": 13754
  },
  "push": {
    "cacheDigest": "AQib_wA",
    "promises": 1,
    "submits": 1,
    "resets": 0
  }
}

-Stefan

> Am 28.07.2016 um 14:38 schrieb Cory Benfield <cory@lukasa.co.uk>:
> 
> All,
> 
> During the HTTP workshop earlier this week, several HTTP/2 implementers expressed a desire to extract information about the state of the H2 connection from the perspective of their peer. This would be extremely useful when developing, debugging, and testing implementations: given that HTTP/2 is so highly stateful the vast majority of interoperability issues come from implementations disagreeing about what the state of the connection is (usually flow control windows!).
> 
> Brad Fitzpatrick and I ended up prototyping a sample approach for getting this information out of server implementations, based on issuing a GET request to a specific well-known URI. This GET would return a JSON document that contains various different pieces of information from inside the implementation, such as window sizes and stream states. In addition, to help debug flow control concerns, the response headers also include information about flow control windows (because if a server believes it is blocked behind flow control it can’t send the JSON document, but it can send the response headers). Examples of this behaviour are available at https://http2.golang.org/.well-known/h2interop/state and https://shootout.lukasa.co.uk/.well-known/h2interop/state.
> 
> The consensus amongst the implementers we spoke to were that this was a good idea, and it would be good to collaborate on the information that should be exposed here. For most HTTP/2 implementers one of the most natural ways to collaborate on something like this is to use an Internet Draft. For that reason, I have submitted the outline of a draft that essentially defines what Brad and I have already done. You can find this draft here: https://tools.ietf.org/html/draft-benfield-http2-debug-state-00
> 
> I have no expectation that this will become a WG document. However, I’d like to bring it to the attention of the working group to ensure that as many implementers as possible can provide feedback on whether this kind of approach is valuable or not, and what information they’d like made available in this kind of mode.
> 
> For anyone who wants to contribute, raise issues, or otherwise help with the draft, it is hosted on GitHub: https://github.com/python-hyper/draft-http2-debug-state. Issues and pull requests are more than welcome, as is feedback on this list.
> 
> Thanks,
> 
> Cory