Re: [squid-users] vary cache rules by time of day

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Sat, 08 Jan 2011 03:37:14 +1300

On 08/01/11 02:06, Tim Huckle wrote:
> Hi,
>
> I'm caching for a short period of time a large number of delayed
> stock market data web service requests which ordinarily were being
> requested from the upstream data provider every time by the app
> layer. I have various refresh_patterns stipulated for the different
> types of requests, i.e. data that compiles a 3 month chart can be
> kept for several hours , a price quote for just a few minutes etc.
>
> Whilst the volume of traffic to our site does drop after market hours
> and over the weekend, we would benefit hugely if I could invoke
> different refresh patterns after market close and over the weekend
> since I know at that point the data can be pulled from cache until
> the market next opens.
>
> Is there a way to do this within acl or refresh_pattern or do I need
> to have two squid configs and cron a --reconfigure at the relevant
> times?

Sadly no. refresh_pattern is purely regex based at present. ACL provides
time-sensitive matches but cannot be used there yet.
  Ideas and patches to convert refresh_pattern to an ACL based directive
are welcome.

Amos

-- 
Please be using
   Current Stable Squid 2.7.STABLE9 or 3.1.10
   Beta testers wanted for 3.2.0.4
Received on Fri Jan 07 2011 - 14:37:19 MST

This archive was generated by hypermail 2.2.0 : Fri Jan 07 2011 - 12:00:02 MST