[PATCH] Make Vary caching work better, take1

From: Alex Rousskov <rousskov_at_measurement-factory.com>
Date: Fri, 08 Nov 2013 12:30:51 -0700

Hello,

    The attached patch contains three fixes related to Vary caching.
These fixes solve some but not all Vary-related problems. The fixes are
extracted from the unofficial bag5s branch on Launchpad but may apply to
trunk and/or v3.[34] as well. Sorry, I did not have the time to check
that and to update related bug reports yet (and I may not be able to do
it soon enough, so I wanted to post these now).

The comments quoted below (extracted from the branch commit log) explain
the details.

HTH,

Alex.

> revno: 12743
> branch nick: bag5s
> Refuse to cache Vary-controlled objects in shared memory (for now).
>
> Shared memory cache code incorrectly assumed that it just needs to keep
> the response and the STORE_META_STD entry details (because that is what
> non-shared memory cache seemed to keep). However, non-shared memory
> cache also keeps MemObject::vary_headers and possibly other meta information
> that cannot be recovered from STORE_META_STD. Thus, we need to store and
> load all serialized meta objects in shared memory, just like the disk
> cache does.
>
> Until the above is implemented, we must disable Vary caching in shared memory
> to avoid "Vary object loop" errors and possibly other problems.

> revno: 12742
> branch nick: bag5s
> Log failed (due to "Vary object loop" or "URL mismatch") hits as TCP_MISSes.

> revno: 12741
> branch nick: bag5s
> Do not start storing the vary marker object until its key becomes public
> or Squid will mark it as "impossible to cache" and will never cache it.

Received on Fri Nov 08 2013 - 19:31:07 MST

This archive was generated by hypermail 2.2.0 : Mon Nov 11 2013 - 12:00:10 MST