cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conal Tuohy" <>
Subject RE: Backend cache invalidation
Date Sat, 24 May 2003 00:57:52 GMT
Hi Peter

Take a look in the CIncludeTransformer. I was looking at the caching code in
this the other day, and it has a feature called "pre-emptive" (I think)
caching which sounds similar to what you want. When the transformer is asked
to include a resource, it serves it immediately from the cache, and then if
necessary it updates the cache in the background, for the next request.
Maybe this is similar to what you're looking for?

It seems to me that this kind of thing would be nice to have in a Source or
something (not sure exactly) so it could be used in other instances, not
just for inclusions.



> -----Original Message-----
> From: Hunsberger, Peter []
> Sent: Saturday, 24 May 2003 01:43
> To: ''
> Subject: Backend cache invalidation
> 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?

View raw message