W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2012

Re: [XHR] Open issue: allow setting User-Agent?

From: Aryeh Gregor <ayg@aryeh.name>
Date: Wed, 17 Oct 2012 10:57:28 +0200
Message-ID: <CAKA+AxnmAznhg8jnez6xAbbn=nmNaSgANa1guDsQPXgRrUzs3A@mail.gmail.com>
To: Boris Zbarsky <bzbarsky@mit.edu>
Cc: Mark Baker <mark@zepheira.com>, Hallvord Reiar Michaelsen Steen <hallvord@opera.com>, Jungkee Song <jungkee.song@samsung.com>, Julian Aubourg <j@ubourg.net>, public-webapps@w3.org
(I noticed people talking about this on IRC and commented, and zcorpan
pointed me to this thread.)

On Tue, Oct 16, 2012 at 7:08 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> The point is that a browser can act as if every single server response
> included "Vary: User-Agent".  And perhaps should.  Intermediary caches
> _certainly_ should.

In terms of correctness, yes, but that will make them useless as
caches.  If a moderate number of users with an assortment of browsers
are using the same caching proxy, it's entirely possible that no two
of them have the same exact User-Agent string.  Varying on User-Agent
in a heterogeneous browser environment is going to drop your cache hit
rate to the point where the cache hurts performance more than it

Proxy caching is always going to break some pages, because not all
pages serve correct caching headers.  This can cause them to break
just due to browser cache too, but more caching is going to break them
more.  So proxy caching is always a correctness-performance tradeoff.
In practice, the loss in correctness is not worth the added
performance for most users, which is why most Internet users are not
(I think?) behind any sort of client-side proxy caching layer.  (I'm
not counting reverse proxies here.)  Where the performance gain is
worth it, such as behind an expensive or high-latency link, users will
just have to be trained to try pressing Ctrl-F5 if pages break.
Received on Wednesday, 17 October 2012 08:58:19 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:49 UTC