In message <[email protected]>, =?iso-88
59-1?Q?Lars_J=F8rgensen?= writes:

>3. User requests index.html. The current object in the cache is banned, so a 
>new version is fetched, stored and deliverd

... and the banned object is expired immediately.

>What is the purpose of banning an object when you could just delete it?

Banning allows you to use a regular expression on any header you want.

"just deleting .*[.].jpg" would take walking over the entire cache
to find all matching objects.

Varnish does this with "lazy evaluation", we only check when we are
about to deliver an object.  This minimizes the work, for instance
objects that expire after then ban was entered without being hit in
the meantime, are not checked.

Purging works by doing a lookup, so you can only do it with a
hash-value (typically URL+Host:), and it expires the objects it find.

Purging is much cheaper, because we can go directly after the objects
we want.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
[email protected]         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.

_______________________________________________
varnish-misc mailing list
[email protected]
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc

Reply via email to