cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sergio Carvalho <>
Subject Re: idle thoughts in caching in c2
Date Mon, 22 Jan 2001 19:42:34 GMT
On Mon, 22 Jan 2001 11:09:41 +0000
Paul Russell <> wrote:

> * Sergio Carvalho ( wrote :
> > On Fri, 19 Jan 2001 13:44:42 -0500 (EST)
> > Donald Ball <> wrote:
> > > do you mean that the caching components should be explicitly put in the
> > > pipeline in the sitemap:
> > > 
> > > <map:cache type="lru"/>
> > Yes. A Cache interface could be defined, so that classes implementing
> > caching are identified. Then, these are placed in the pipeline,
> > between each data-producer (or processor) and the subsequent
> > data-consumer. 
> That makes sense. Would we then stick a binary cache on the output
> regardless, or should that be explicit too? (Or do we not put a binary
> cache on at all, and leave it to an http level cache?)

What are you calling a binary cache? Storage of the document in binary form? Is it possible
to do a memory snapshot in Java, as it is sometimes used in C to avoid parsing cached data?

I don't think HTTP caches are a solution here. Cocoon doesn't use HTTP for intermediate steps,
so HTTP caches cache the whole page; which is useful but doesn't go as far as we need. I want
Cocoon caches to be able to store intermediate steps (like menu generation, for example).

There is another design refactoring possible here, but it is probably an overkill: In this
caching model, a cache class handles two things, cache policies and cache storage. Truly,
in OO design, these should be handled separately, and used through delegation. Something like
having these classes:

- Policies:
- Stores:

And then have small&simple cache processors that delegate in one policy class and one
store class:
Again, this is probably an overkill. 

I promise I'll implement/aid implementing some of these ideas in mid-february, if there's
no cache in C2 by mid-february, when my current project finishes and I get time to breathe.

> Paul.
> -- 
> Paul Russell                                 Email:
> Technical Director                             Tel:  +44 (0)20 8553 6622
> Luminas Internet Applications                  Fax:  +44 (0)870 28 47489
> This is not an official statement or order.    Web:
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, email:

Sergio Carvalho

If at first you don't succeed, skydiving is not for you

View raw message