Retrieving the age of a given key

Brian Moon brianm at
Fri Aug 18 19:57:56 UTC 2006

> To make it work, I would need to know the age of any given key.  Using 
> the more-traditional expiration feature of memcached can lead to having 
> an inconsistent set of data.  It would also be very difficult to flush 
> the appropriate keys as these hourly updates are published.

How does the expiration feature lead to inconsistent data?  If the 
updates are hourly, then your expire time should be hourly.  To use 
memcached, you may have to rethink your system a little bit.  We have 
processes that update existing cache.  We simply overwrite it using set. 
  In fact, we never use add with memcached as we always want the new 
data to overwrite the old data.


Brian Moon
Its good to be cheap =)

More information about the memcached mailing list