Re: The use of binary data in any part of HTTP 2.0 is not good

Mark Nottingham <mnot@mnot.net> Sun, 20 January 2013 23:48 UTC

Return-Path: <ietf-http-wg-request@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 9EF8B21F8727 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Sun, 20 Jan 2013 15:48:28 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.925
X-Spam-Level:
X-Spam-Status: No, score=-7.925 tagged_above=-999 required=5 tests=[AWL=0.075, RCVD_IN_DNSWL_HI=-8]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id a0sokzNipD-o for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Sun, 20 Jan 2013 15:48:27 -0800 (PST)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) by ietfa.amsl.com (Postfix) with ESMTP id 93A8221F8718 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Sun, 20 Jan 2013 15:48:27 -0800 (PST)
Received: from lists by frink.w3.org with local (Exim 4.72) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1Tx4cI-0004n0-Kz for ietf-http-wg-dist@listhub.w3.org; Sun, 20 Jan 2013 23:47:58 +0000
Resent-Date: Sun, 20 Jan 2013 23:47:58 +0000
Resent-Message-Id: <E1Tx4cI-0004n0-Kz@frink.w3.org>
Received: from maggie.w3.org ([128.30.52.39]) by frink.w3.org with esmtp (Exim 4.72) (envelope-from <mnot@mnot.net>) id 1Tx4cD-0004m1-O8 for ietf-http-wg@listhub.w3.org; Sun, 20 Jan 2013 23:47:53 +0000
Received: from mxout-07.mxes.net ([216.86.168.182]) by maggie.w3.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from <mnot@mnot.net>) id 1Tx4cC-00012A-S0 for ietf-http-wg@w3.org; Sun, 20 Jan 2013 23:47:53 +0000
Received: from mnot-mini.mnot.net (unknown [118.209.240.13]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by smtp.mxes.net (Postfix) with ESMTPSA id 380A222E1F4; Sun, 20 Jan 2013 18:47:28 -0500 (EST)
Content-Type: text/plain; charset="utf-8"
Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\))
From: Mark Nottingham <mnot@mnot.net>
In-Reply-To: <CABP7Rbdft=ukmL+vgyJtSTRSVytxMFkX6ctqhqhJ2Njw_OLr1g@mail.gmail.com>
Date: Mon, 21 Jan 2013 10:47:25 +1100
Cc: Tim Bray <tbray@textuality.com>, "ChanWilliam(陈智昌)" <willchan@chromium.org>, HTTP Working Group <ietf-http-wg@w3.org>, Pablo <paa.listas@gmail.com>
Content-Transfer-Encoding: quoted-printable
Message-Id: <E248E7BA-E173-44F8-99A2-C7B3547A9CE8@mnot.net>
References: <CAAZO4q4vEiYhH5FaX2XCxXox9jkf4dLTy8coQZiE+CYHA-QzBg@mail.gmail.com> <CAA4WUYhkVBRAyY1O32aOiWB8=46SBidFOjKH+e7PGbB7mKzmiQ@mail.gmail.com> <DC03C924-9DCC-45CE-B9DB-5906EADAF9C4@mnot.net> <CAHBU6iuaeAeTrz6TSOyhNvW2pXWgQB_RQ+6MYAb9DyJUZ00Rcg@mail.gmail.com> <CABP7Rbdft=ukmL+vgyJtSTRSVytxMFkX6ctqhqhJ2Njw_OLr1g@mail.gmail.com>
To: James M Snell <jasnell@gmail.com>
X-Mailer: Apple Mail (2.1499)
Received-SPF: pass client-ip=216.86.168.182; envelope-from=mnot@mnot.net; helo=mxout-07.mxes.net
X-W3C-Hub-Spam-Status: No, score=-4.2
X-W3C-Hub-Spam-Report: AWL=-2.327, BAYES_00=-1.9, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001
X-W3C-Scan-Sig: maggie.w3.org 1Tx4cC-00012A-S0 3f9c5baead503eb3fa90e8d1af88f027
X-Original-To: ietf-http-wg@w3.org
Subject: Re: The use of binary data in any part of HTTP 2.0 is not good
Archived-At: <http://www.w3.org/mid/E248E7BA-E173-44F8-99A2-C7B3547A9CE8@mnot.net>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/16059
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>

Well, there are two aspects; one is the encoding for the headers, the other is the framing for the protocol itself.

Additionally, binary can bring benefits in size, leading to performance benefits. However, it can also bring scalability benefits, because it's a lot easier to parse, requiring less memory / copying / look-ahead...

Measuring size benefits is fairly straightforward (as we're already doing <http://http2.github.com/http_samples/>); measuring scalability benefits is more implementation- and deployment-specific, and so more difficult. We can try, however.

FWIW, my "simple" approach *is* textual*, at least for the header encoding part of the problem. Textual framing is also possible, of course, but it's going to come at a fair overhead (in terms of size and in terms of processing overhead), I suspect.

If anyone is interested in pursuing these approaches, an Internet-Draft making a concrete proposal is the best way to get our attention. And of course, if people want to see measurements, they can pitch in (as things seldom measure themselves).

Cheers,


* Or, at least, it was until a few days ago, when I switched to a 7-bit encoding of ASCII; that can be disabled (at a cost of 12.5% efficiency, naturally).




On 21/01/2013, at 10:36 AM, James M Snell <jasnell@gmail.com> wrote:

> This is still being worked out really, qualitative numbers will be coming. So far, however, we're talking about around a 50% reduction in header overhead on the wire without compression. Obviously, however, we're no where near being done yet.
> 
> On Jan 20, 2013 3:26 PM, "Tim Bray" <tbray@textuality.com> wrote:
> Would it be possible to be data-driven?  Textual formats are
> well-known to be easier to debug; but clearly, if there’s a
> substantial performance benefit to going all-binary, so be it. So what
> is the advantage, quantitatively? -T
> 
> On Sun, Jan 20, 2013 at 3:04 PM, Mark Nottingham <mnot@mnot.net> wrote:
> > In one of our recent meetings, one of the grey-bearded IETF old-timers (I forget which, sorry) said that a textual-protocol was a nice-to-have, but that it shouldn't be a determining factor in design.
> >
> > I.e., if you can get everything you need out of a protocol, *and* make it textual, do so, but if it detracts from the value you get from it, don't let that constrain you.
> >
> > FWIW, I think that's a good rule of thumb. However, this means that the community is going to need *excellent* tooling for analysing, debugging, etc. HTTP traffic; and I don't just mean a Wireshark plugin!
> >
> > Cheers,
> >
> >
> > On 21/01/2013, at 9:36 AM, William Chan (陈智昌) <willchan@chromium.org> wrote:
> >
> >> There are many advantages to using binary data. If you would like a
> >> textual representation of a protocol, I advise using a utility to
> >> generate one for you.
> >>
> >> On Sun, Jan 20, 2013 at 2:20 PM, Pablo <paa.listas@gmail.com> wrote:
> >>> Hello,
> >>>
> >>>   I have readed this document
> >>> http://dev.chromium.org/spdy/spdy-protocol/spdy-protocol-draft1 today [1].
> >>>
> >>> I just wanted to say that I think that the use of any binary data (framing,
> >>> header compression, etc.) in any place of the "header" part of HTTP protocol
> >>> is not good; so, please only use plaintext for HTTP 2.0 because, otherwise,
> >>> that will make very difficult to "see" the headers's protocol :)
> >>>
> >>> Thats all,
> >>> Thanks for reading this few lines, sorry for my basic English, and I hope
> >>> that you can re-think all this of using binary data in any part of HTTP X.X
> >>> (ej: session layer).
> >>>
> >>>
> >>> [1] I started knowing about HTTP 2.0 here:
> >>> http://webscannotes.com/2012/10/09/http-2-0-officially-in-the-works/
> >>>
> >>
> >
> > --
> > Mark Nottingham   http://www.mnot.net/
> >
> >
> >
> >
> 

--
Mark Nottingham   http://www.mnot.net/