Re: Expiration scans...

From: Mark Treacy <>
Date: Fri, 01 Nov 1996 11:36:28 +1100

> It scans the entire cache roughly every 24 hours, one bucket at a time.
Eventually I'd like to make the scan period configurable. The problem
is calculating an optimum number of buckets to scan and the rate at which
to do the scan (the number of buckets in the store table is now selected
based on the configured size of the cache).

> It removes expired objects, ie:
> negative-cached objects
> objects which have not been referenced for longer than 'reference_age'
> The 'reference_age' parameter is disabled by default, and alas undocumented.
The implementation of the reference_age parameter isn't yet completed. I
included the partial implementation with the recent hash changes because
it is still potentially useful.

A few months ago I conducted a study of the reference patterns to a busy
cache. One of my findings was that of the objects that where actually hit
upon after entering the cache, a large percentage of these subsequent hits
occured within the first 24 hours (63%). About 42% of the hits occured
within the first hour.

Based on this I concluded that it was viable to implement an expiration
policy that deleted objects that had been recently referenced (within say
24 hours). reference_age is the configuration parameter that sets this

What is still missing is that the policy wont work properly across
restarts. The time of last reference needs to also been written to
the cache log.

 - Mark.
Received on Thu Oct 31 1996 - 16:36:38 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:33:25 MST