First hit always cached.

david raistrick drais at icantclick.org
Tue Sep 4 18:11:31 CEST 2012


On Tue, 4 Sep 2012, Rosco Nap wrote:

> Is it possible to have the first hit on a frontpage index (eq: 
> www.example.com/index.php) be served from Varnish, and every hit after 
> that redirected to the backend?


A "first" hit, by definition, couldn't already be in the cache - and so 
couldn't be served from the cache. (you could preload your cache, but 
really that would be the "first" hit...)


The whole point of a cache is to reduce hits (decreasing load or latency) 
to the backend - what possible problem would your solution solve?


--
david raistrick        http://www.netmeister.org/news/learn2quote.html
drais at icantclick.org       ascii ribbon campaign - stop html mail
                                 http://www.asciiribbon.org/






More information about the varnish-misc mailing list