cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vadim Gritsenko <>
Subject Re: CLI caching, etc
Date Thu, 17 Apr 2003 20:44:28 GMT
Upayavira wrote:

>>>>Before you go further with this... Look at method
>>>>isResponseModified() in [1].
>>>>What you need to do is to:
>>>>1. Implement method isResponseModified() for command line
>>>>environment. 2. In the CLI, get the file corresponding to the
>>>>request URI, and get its last modification time. 3. Populate
>>>>environment with this modification time (this will be similar to
>>>>If-Modified-Since date header in http). 4. Call cocoon. It will skip
>>>>generation if response is not modified, and won't even read it from
>>>Very interesting. So Cocoon can tell me if something has been
>>>modified. Great. 
>>Yes, and it works in http env.
>I've implemented something around this, with a cache that seems more or less to 
>work. However, when I run org.apache.cocoon.Cocoon.process(), my methods that 
>I've implemented on the AbstractCommandLineEnvironment do not get called (i.e. 
>isResponseModified and setResponseIsNotModified). What do I need to do to get 
>Cocoon to actually call these methods on my environment?

/me doing some digging...

There is a reference to the isResponseModified in 
AbstractProcessingPipeline.checkLastModified [1]. From what I see, this 
method is intended to work only for readers. Which is unfortunate. What 
do you think - can we extend pipeline implementation to support this for 
event pipelines too? Sylvain / Carsten, opinion? :-)

(I don't have Cocoon checkout at hands right now; so can't give better 



View raw message