cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hunsberger, Peter" <Peter.Hunsber...@stjude.org>
Subject Backend cache invalidation
Date Fri, 23 May 2003 13:42:40 GMT
It seems to me that this must be a classic Cocoon problem, but I really
haven't found any discussion of it or how to solve it:

We have a generator that creates some content (from a database via EJBs)
that for 99.99% of the time is unchanging.  Every once and a while an end
user (with admin rights) will make a change to this content and immediately
expect all users to be able to see the changes upon a subsequent refresh of
the relevant screen.  The content is expensive to generate and it makes
sense to cache it.  We could in fact cache it once and for ever if we didn't
have the occasional update.

Is there currently any way to have the back end signal to Cocoon that a
particular cache item needs to be invalidated?  We're thinking of building a
MX Bean listener that would register itself with a common proxy super class
for all EJBs.  Then upon successful insert or update on the back end the
proxy classes would signal the listener to blow away the particular cache
entry.  Essentially this would be something like a
BackEndListenerCacheValidty (or BackEndCheckingCacheValidity although it
doesn't really check) class.  Does this make sense? Does Cocoon or anyone
have anything like this already?

Peter Hunsberger

<Debating on whether to unleash the following Russell quote on the
world.../>

The infliction of cruelty with a good conscience is a delight to moralists -
that is why they invented hell.
Bertrand Russell (1872 - 1970)
 

Mime
View raw message