Prefetching
Anders Berg
andersb at vgnett.no
Tue Aug 1 19:11:06 CEST 2006
Hi,
since I am still at home with a bad back (I can only sit for small amounts
of time in a chair), I have been reading some papers on prefetching and
cache algorithm's. I have concluded this:
1. Prefetching is only needed if one wants to minimalize latency for
doc's, or to prime a cache. Obvious maybe, but I can't think of any other
use. Bandwith is hardly a problem to backend, and size is not to big a
deal for most cases.
2. If we wanna use a algorithm, we would use a old one. Reason is that the
"new" ones are so clientside-cache oriented that to perform better than
the old'ies they become so specific whith regards to different paramaters
for optimalization, that they don't fit good for serverside-caching (They
take into account bandwith, size etc...). I have not read at all about the
newest ones, but it is clear already in year 2000 that they fit clientside
better than serverside. And since we would possibly use prefetching for
latency I would opt for one called Hybrid,
http://dret.net/biblio/reference/woo97 (I can't seem to find it online,
but it is explained in:
http://www.usenix.org/publications/library/proceedings/usits97/full_papers/cao/cao.pdf).
Hybrid takes into account alot of parameters but primary focus is latency.
It does not require extra HTTP headers, and is pretty simple. The only
drawback is scaleability, O(log k) where k is number of docs. LRU is O(1),
but LRU is basically useless, since it won't help latency and prefetching
much.
I can't remember where we are with regards to prefetch, but I thought I
might wanna write this down anyway.
Anders Berg
More information about the varnish-dev
mailing list