> 1) The old cache entry is overwritten with the new.
> 2) The old cache entry is expired, thus forcing a database hit (and 
> subsequent cache load) on the next request.

3) Cache only stuff which doesn't expire (except on server restarts).

We don't cache any mutable data, and there are no sessions. We let the
database do the caching.  We use Oracle, which has a pretty good
cache.  We do cache some stuff that doesn't change, e.g. default
permissions, and we release weekly, which involves a server restart
and a refresh of the cache.

If you hit http://www.bivio.com , you'll get a page back in under
300ms. There are probably 10 database queries involved if you are
logged in.  This page is complex, but far from our most complex.
For example, this page
http://www.bivio.com/demo_club/accounting/investments
sums up all the holdings of a portfolio from the individual
transactions (buys, sells, splits, etc.).  It also comes back in under
300ms.

Sorry if this wasn't the answer you were looking for. :)

Rob

Reply via email to