Re: Straw Poll: Restore Header Table and Static Table Indices

Willy Tarreau <w@1wt.eu> Tue, 21 October 2014 09:47 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 (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id A21C01A0360 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 21 Oct 2014 02:47:59 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.912
X-Spam-Level:
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 mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZKKcJskiUP1q for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 21 Oct 2014 02:47:57 -0700 (PDT)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id C4D4D1A1A06 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Tue, 21 Oct 2014 02:44:59 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.72) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1XgVxP-0001Hy-C8 for ietf-http-wg-dist@listhub.w3.org; Tue, 21 Oct 2014 09:42:23 +0000
Resent-Date: Tue, 21 Oct 2014 09:42:23 +0000
Resent-Message-Id: <E1XgVxP-0001Hy-C8@frink.w3.org>
Received: from lisa.w3.org ([128.30.52.41]) by frink.w3.org with esmtp (Exim 4.72) (envelope-from <w@1wt.eu>) id 1XgVxF-0001HA-Do for ietf-http-wg@listhub.w3.org; Tue, 21 Oct 2014 09:42:13 +0000
Received: from 1wt.eu ([62.212.114.60]) by lisa.w3.org with esmtp (Exim 4.72) (envelope-from <w@1wt.eu>) id 1XgVxE-0002ZJ-Fw for ietf-http-wg@w3.org; Tue, 21 Oct 2014 09:42:13 +0000
Received: (from willy@localhost) by mail.home.local (8.14.4/8.14.4/Submit) id s9L9eXch030859; Tue, 21 Oct 2014 11:40:33 +0200
Date: Tue, 21 Oct 2014 11:40:33 +0200
From: Willy Tarreau <w@1wt.eu>
To: Roberto Peon <grmocg@gmail.com>
Cc: Mark Nottingham <mnot@mnot.net>, RUELLAN Herve <Herve.Ruellan@crf.canon.fr>, Amos Jeffries <squid3@treenet.co.nz>, Greg Wilkins <gregw@intalio.com>, "ietf-http-wg@w3.org" <ietf-http-wg@w3.org>
Message-ID: <20141021094032.GB30397@1wt.eu>
References: <CAHzwyDuuN=-DyGiWAfttwq7O_zUGOE=7kVf5J=qu6i_-A9ezfg@mail.gmail.com> <543E0400.8080009@treenet.co.nz> <20141015201540.GB980@1wt.eu> <6C71876BDCCD01488E70A2399529D5E53BF5F842@ADELE.crf.canon.fr> <20141016091626.GC3079@1wt.eu> <34008D72-5800-412E-A276-81C6C7BFA9E2@mnot.net> <20141020165353.GA25743@1wt.eu> <8F120E2F-704E-44CB-ACF2-C743B870B2B6@mnot.net> <CAP+FsNdOHVj=YTE35Vj7mbED0OKghd-mpnFZSMcZNBM3JybJDg@mail.gmail.com> <20141021092505.GA30397@1wt.eu>
Mime-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: inline
In-Reply-To: <20141021092505.GA30397@1wt.eu>
User-Agent: Mutt/1.4.2.3i
Received-SPF: pass client-ip=62.212.114.60; envelope-from=w@1wt.eu; helo=1wt.eu
X-W3C-Hub-Spam-Status: No, score=-3.8
X-W3C-Hub-Spam-Report: AWL=-2.343, RP_MATCHES_RCVD=-1.43, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001
X-W3C-Scan-Sig: lisa.w3.org 1XgVxE-0002ZJ-Fw d3f90f6d57aa2f2588f15af72c628317
X-Original-To: ietf-http-wg@w3.org
Subject: Re: Straw Poll: Restore Header Table and Static Table Indices
Archived-At: <http://www.w3.org/mid/20141021094032.GB30397@1wt.eu>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/27652
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 Tue, Oct 21, 2014 at 11:25:05AM +0200, Willy Tarreau wrote:
> Hi Roberto,
> 
> On Tue, Oct 21, 2014 at 12:01:19AM -0700, Roberto Peon wrote:
> > While I prefer the indexing scheme of the previous draft, this proposal
> > would be better than what is currently drafted.
> 
> Thanks. Do you know how the following representations are ordered in
> terms of frequency/probability ?
> 
>   - Indexed Header Field Representation
>   - Literal Header Field with Incremental Indexing
>   - Literal Header Field without Indexing
>   - Literal Header Field never Indexed
> 
> I would guess they should appear in the order above, though that's not
> obvious to me. And I'm still sad at the idea of leaving many encoding
> values unused (eg: static header values above 16). Thus, we'll typically
> have 48 possible values out of 256 for the first byte that will never be
> emitted just for the indexed headers alone, that's a 20% waste, and I
> really think we can do better without making anything more complex. I
> just need to ensure I don't propose something stupid.

For example something like this (CCing Greg who also has concerns about
all this), which supports a single-byte encoding for :
   - 14 or the 16 static headers with values
   - all 62 static headers for literals
   - 62 dynamic headers for literals

   +---+---+----------------------+
   | 1 | D |  index 6+            |      literal with incremetal indexing
   +---+---+----------------------+

   +---+---+----------------------+
   | 0 | 1 |  index 6+            |      indexed dynamic header
   +---+---+----------------------+

   +---+---+---+---+--------------+
   | 0 | 0 | 1 | 1 |  index 4+    |      indexed static header
   +---+---+---+---+--------------+

   +---+---+---+---+--------------+
   | 0 | 0 | 1 | 0 |  size 4+     |      max dynamic table size change
   +---+---+---+---+--------------+

   +---+---+---+---+---+----------+
   | 0 | 0 | 0 | 0 | D | index 3+ |      literal without indexing 
   +---+---+---+---+---+----------+

   +---+---+---+---+---+----------+
   | 0 | 0 | 0 | 1 | D | index 3+ |      literal never indexed
   +---+---+---+---+---+----------+

Willy