Cache dynamic URLs

Per Buer perbu at varnish-software.com
Fri Mar 4 08:48:05 CET 2011


On Thu, Mar 3, 2011 at 5:35 PM, Iliya Sharov <isharov at yandex-team.ru> wrote:

>  Hi.
> May be
> sub vcl_hash
> {
>         set req.hash
> +=req.url;
>
>
> return(hash);
> }
>

This part isn't necessary.

>
> sub vcl_fetch
> {
>         if (req.url ~ "(php") { set beresp.ttl =30s;}
> }
>

It will work.


> and  -p lru_interval=30 in command-line run options?
>

This is also not relevant. I wouldn't recommend screwing around with
parameters unless it is called for and you're know what you're doing.


-- 
Per Buer, Varnish Software
Phone: +47 21 98 92 61 / Mobile: +47 958 39 117 / Skype: per.buer
Varnish makes websites fly!
Want to learn more about Varnish?
http://www.varnish-software.com/whitepapers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20110304/7514512c/attachment-0003.html>


More information about the varnish-misc mailing list