cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sylvain Wallez <>
Subject Re: [PROPOSAL] "CachingPoint" Caching algorithm
Date Mon, 17 Jun 2002 12:05:33 GMT
Michael Melhem wrote:

>Hi all,
>I have started work on new caching algoritm which is refered to as
>the "cachingPoint" alogrithm.
>The developer can configer certain pipelines to use this alogrithm as
>required. The cahingPoint algorithm is of best value when a pipeline uses lots
>"cocoon-views" or selectors or contains drill-down functionality
>The idea of cache points is instead of simply caching the longest
>possible key in a given pipeline, we also strategically cache points along the way.
>When building a pipeline, we mark as "cachepoint" the last component in
>the pipeline if next component needs to be chosen from a set of
>possible components (ie we come a cross a branch or fork in the process tree)
>Tha advanatge of this algorithm is that common segments of a pipeline are cached
>ready for reuse.
>Perhaps the basic idea can be best illustrated with a very simple
>Consider the following sitemap:
> <map:view name="content" from-label="content">
>   <map:serialize type="xml"/>
> </map:view>
> <map:match pattern="welcome">
>   <map:generate src="samples.xml" label="content"/>
>   <map:transform src="common/style/xsl/html/simple-samples2html.xsl"/>
>   <map:serialize type="html"/>
> </map:match>
>For the the request:/welcome the default caching algorithm would cache a
>single cache entry using key determined by the
>generator+transformer+HTMLserializer: PCK:CCK:1file:CCK:3xsltCCK:5html
>When we fire of the request:/welcome?cocoon-view=content, the default
>algorithm would look up the cache for the key: PCK:CCK:1file:CCK:5xml
>(determined by generator+XMLserializer) and find nothing. Even though
>we are generating the exact same information, this information is not cached.
>The proposed caching alagorithm would resolve this issue by caching along side
>the full result, the result of the generator as well. This is because the
>generator would be designated as a "cachepoint" in this case.
>Feedback is welcome.

That's a very interesting proposal, as it can speedup a lot 
multi-channel applications. However, you forgot to say how do you flag a 
sitemap component as being a cache point ?
Does it require a specific attribute (<map:generate src="foo.xml" 
cachepoint="true"/>) ?
Can it be related to view labels (<map:view name="foo" 
from-label="foolabel" cachepoint="true") ?


Sylvain Wallez
  Anyware Technologies                  Apache Cocoon 

To unsubscribe, e-mail:
For additional commands, email:

View raw message