httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Noordhuis <i...@bnoordhuis.nl>
Subject Re: Vary:User-Agent, best practices, and making the web faster.
Date Sun, 05 Jun 2011 11:32:02 GMT
On Sun, Jun 5, 2011 at 02:15, Joshua Marantz <jmarantz@google.com> wrote:
> On Sat, Jun 4, 2011 at 7:58 PM, Ben Noordhuis <info@bnoordhuis.nl> wrote:
>> Some popular OSS packages depend on Vary: User-Agent to make
>> downstream proxies (reverse or forward) do the right thing.
>
> I'm pretty interested in deconstructing this further.  Can you be more
> specific?   Which OSS packages?  Under what scenario would a proxy do the
> wrong thing in the absence of Vary:User-Agent (other than, obviously, when
> the content actually varies based on user-agent)?

>From first-hand experience (because I broke it): Magento, a popular
PHP e-commerce framework. Magento (or one of its plug-ins) generates
browser-tailored HTML and sets the Vary header to ensure that
downstream proxies send the right HTML to the right client. If you
remove or ignore the header, the layout of your site breaks.

There are CPAN modules and Rack middleware that do similar things and
no doubt other software too.

Mime
View raw message