cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Grzegorz Kossakowski (JIRA)" <>
Subject [jira] Commented: (COCOON-2009) Pipelines more HTTP-compliant (respecting and producing HTTP headers and status codes)
Date Thu, 22 Feb 2007 13:45:05 GMT


Grzegorz Kossakowski commented on COCOON-2009:

Thanks for spotting this. Your concerns are justified and I agree that we should use getLastModified
of the response stored in cache. The problem is that cachedResponse variable will be null
at this point of processing. Why? Because it's used only for _serving_ cached response. When
you look into dark details of the AbstractCachingProcessingPipeline you'll see that cachedResponse
variable is set during validation of pipeline. That means, if cachedResponse is still valid
the variable is set. 
Solution for this situation that would not confuse things even more is returning cachedResponse
as result of cacheResults.

I've chosen much simpler (and it's seems invalid) way as I really don't like changing sitemap/pipeline
code. To stay reserved and courteous I will only say that the code is messy and inconsistent...

I also have not been aware of this:
Because otherwise it might happen that Last-Modified == new Date().getTime() (>this.cachedResponse.getLastModified())
the first time the pipeline is called and that the next and future times the pipeline is called
it will (due to line 279 in AbstractCachingProcessingPipeline.processXMLPipeline) have Last-Modified==this.cachedResponse.getLastModified().

It's really good point.

> Pipelines more HTTP-compliant (respecting and producing HTTP headers and status codes)
> --------------------------------------------------------------------------------------
>                 Key: COCOON-2009
>                 URL:
>             Project: Cocoon
>          Issue Type: Improvement
>          Components: - Components: Sitemap
>    Affects Versions: 2.2-dev (Current SVN)
>            Reporter: Grzegorz Kossakowski
>             Fix For: 2.2-dev (Current SVN)
>         Attachments: cocoon-pipeline-impl-http-compliant-patch-1.txt
> This issue was discussed a little here:
> Main aim is to respect cache-related headers and produce necessary information for clients
to do proper caching.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message