[squid-users] Vary object loop returns

Amos Jeffries squid3 at treenet.co.nz
Wed Jun 8 16:58:13 UTC 2016

On 9/06/2016 4:02 a.m., Heiler Bemerguy wrote:
> Hum.. Amos, that store_miss would just make the object with that Vary
> header to not be cached, right?

It will prevent caching for any object using a Vary which matches any of
the ACLs regex patterns. The patterns being ones which match the headers
that are known to cause variant explosions.

> I've just tested it. But I think we need to choose what types of Vary
> are valid/usable or not.


> Reading the source code since yesterday, I made a patch that seems to
> fix my vary loop problem and will increase HITs a lot.
> It will only accept "accept-encoding" as a Vary statement and ignore all
> the other garbage servers are using as "Vary"...
> A simple change on http.cc, not client_side.cc

I think your patch is identical to hard-coding the config:

 acl vary rep_header Vary -i .
 acl varyAE rep_header Vary -i ^accept-encoding$
 store_miss deny vary !varyAE

It is not reasonable to hard-code these things in a widely used generic
HTTP proxy like Squid. If it can be configured do it that way, if it
can't then config needs to be added.


More information about the squid-users mailing list