]> git.ipfire.org Git - thirdparty/squid.git/commit
Support more collapsed forwarding hit cases:
authorAlex Rousskov <rousskov@measurement-factory.com>
Wed, 25 Jun 2014 00:09:35 +0000 (18:09 -0600)
committerAlex Rousskov <rousskov@measurement-factory.com>
Wed, 25 Jun 2014 00:09:35 +0000 (18:09 -0600)
commit0cdcf3d70d27ec296a6a6dad381d9b2bf3d3081a
tree068fa4ee6328c4de7655c7f1ab5083e871833bff
parent41afe8b27555949b1ef75c21fb2a388a8730fd15
Support more collapsed forwarding hit cases:

Allow STORE_MEMORY_CLIENTs to open disk files if needed and possible.
STORE_*_CLIENT designation is rather buggy (several known XXXs). Some
collapsed clients are marked as STORE_MEMORY_CLIENTs (for the lack of info at
determination time) but their hit content may actually come from a disk cache.

Do not abandon writing a collapsed cache entry when we cannot cache the entry
in RAM if the entry can be cached on disk instead. Both shared memory cache
and the disk cache have to refuse to cache the entry for it to become
non-collapsible. This dual refusal is difficult to detect because each cache
may make the caching decision at different times. Added StoreEntry methods to
track those decisions and react to them.

Recognize disk cache as a potential source of the collapsed entry when the
memory cache is configured. While collapsed entries would normally be found in
the shared memory cache, caching policies and other factors may prohibit
memory caching but still allow disk caching. Memory cache is still preferred.
src/MemStore.cc
src/Store.h
src/StoreClient.h
src/store.cc
src/store_client.cc
src/store_dir.cc
src/store_swapout.cc