[Varnish] #793: TTL randomizing
Varnish
varnish-bugs at varnish-cache.org
Mon Oct 11 13:57:00 CEST 2010
#793: TTL randomizing
--------------------------------------+-------------------------------------
Reporter: tmagnien | Owner: phk
Type: enhancement | Status: closed
Priority: normal | Milestone:
Component: varnishd | Version: trunk
Severity: normal | Resolution: fixed
Keywords: expiry randomization ttl |
--------------------------------------+-------------------------------------
Changes (by phk):
* status: new => closed
* resolution: => fixed
Comment:
(In [5421]) Add REAL std.random(REAL low, REAL high) with associated
testcase.
Example usage:
sub vcl_fetch {
/* Spread TTLs -10%..+5% because CMS timestamps whole minutes */
set beresp.ttl = beresp.ttl * random(0.90, 1.05);
}
This usage was one of the very first VCL examples we ever wrote on
a whiteboard, we just never got a round tuit until now.
Fixes: #793
--
Ticket URL: </ticket/793#comment:1>
Varnish <http://varnish-cache.org/>
The Varnish HTTP Accelerator
More information about the varnish-bugs
mailing list