Re: Reference set in HPACK

Mark Nottingham <mnot@mnot.net> Wed, 02 July 2014 05: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 339131B28C5 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 1 Jul 2014 22:47:27 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.253
X-Spam-Level:
X-Spam-Status: No, score=-7.253 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, MIME_8BIT_HEADER=0.3, RCVD_IN_DNSWL_HI=-5, RP_MATCHES_RCVD=-0.651, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] 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 W4a9PYaF1Tp1 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 1 Jul 2014 22:47:24 -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 216A21B28BF for <httpbisa-archive-bis2Juki@lists.ietf.org>; Tue, 1 Jul 2014 22:47:24 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.72) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1X2DMA-0005Vo-RI for ietf-http-wg-dist@listhub.w3.org; Wed, 02 Jul 2014 05:45:22 +0000
Resent-Date: Wed, 02 Jul 2014 05:45:22 +0000
Resent-Message-Id: <E1X2DMA-0005Vo-RI@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 1X2DM2-0004Mm-90 for ietf-http-wg@listhub.w3.org; Wed, 02 Jul 2014 05:45:14 +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 1X2DM1-0001aK-2P for ietf-http-wg@w3.org; Wed, 02 Jul 2014 05:45:13 +0000
Received: from [192.168.1.55] (unknown [118.209.193.75]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by smtp.mxes.net (Postfix) with ESMTPSA id 9912122E1FA; Wed, 2 Jul 2014 01:44:44 -0400 (EDT)
Content-Type: text/plain; charset="utf-8"
Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.2\))
From: Mark Nottingham <mnot@mnot.net>
In-Reply-To: <20140702.143041.283993814131065692.kazu@iij.ad.jp>
Date: Wed, 02 Jul 2014 15:44:41 +1000
Cc: ietf-http-wg@w3.org
Content-Transfer-Encoding: quoted-printable
Message-Id: <8C93AEC0-BA12-48AC-A66B-E447E074FCD2@mnot.net>
References: <20140702.143041.283993814131065692.kazu@iij.ad.jp>
To: "\"Kazu Yamamoto (山本和 彦)\"" <kazu@iij.ad.jp>
X-Mailer: Apple Mail (2.1878.2)
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=-3.7
X-W3C-Hub-Spam-Report: AWL=-3.041, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001
X-W3C-Scan-Sig: maggie.w3.org 1X2DM1-0001aK-2P 3bcd657c97b6eafc65e92b7fa03e8822
X-Original-To: ietf-http-wg@w3.org
Subject: Re: Reference set in HPACK
Archived-At: <http://www.w3.org/mid/8C93AEC0-BA12-48AC-A66B-E447E074FCD2@mnot.net>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/25028
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>

Hi Kazu,

As I understand it, one of the purposes of the reference set is to accommodate cases where intermediaries multiplex requests from different clients -- thus having different cookies, UAs, etc. -- into one upstream connection.

Does your test data reflect this kind of use case?

Regards,


On 2 Jul 2014, at 3:30 pm, Kazu Yamamoto (山本和彦) <kazu@iij.ad.jp> wrote:

> Hi,
> 
> As you may remember, I implemented several HPACK *encoding* algorithms
> and calculated compression ratio. I tried it again based on HPACK
> 08. I have 8 algorithms.
> 
> - Naive    -- No compression
> - Naive-H  -- Using Huffman only
> - Static   -- Using static table only
> - Static-H -- Using static table and Huffman
> - Linear   -- Using header table
> - Linear-H -- Using header table and Huffman
> - Diff     -- Using header table and reference set
> - Diff-H   -- Using header table, reference set and Huffman
> 
> The implementations above pass all test cases in
> https://github.com/http2jp/hpack-test-case/.  Using this test cases as
> input, I calculated compression ratio again. The ratio is calculated
> by dividing the number of bytes after compression by that before
> compression.
> 
> Here is results:
> 
> Naive     1.10
> Naive-H   0.86
> Static    0.84
> Static-H  0.66
> Linear    0.39 
> Linear-H  0.31
> Diff      0.39
> Diff-H    0.31
> 
> Linear-H and Diff-H results in almost the same. To my calculation,
> Diff-H is only 1.6 byte shorter than Linear-H in average. This means
> that reference set does NOT much contribute to compress headers
> although it is very difficult to implement.
> 
> I have NOT seen any header examples for which reference set work
> effectively so far.
> 
> So, if the authors of HPACK want to retain reference set, I would like
> to see evidence that there are some cases in which reference set
> contributes the compression ratio. HPACK 08 says "Updated Huffman
> table, using data set provided by Google". So, I guess that the
> authors can calculate the compression ratio based on this data.
> 
> If there is not such an evidence, I would like to strongly recommend
> to remove reference set from HPACK. This makes HPACK much simpler, so
> implementations gets bug less and inter-operability is improved. Plus,
> the order of headers is reserved always.
> 
> Regards,
> 
> --Kazu
> 
> 
> 
> 
> 

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