[Grok-dev] Re: KSS lag?

Philipp von Weitershausen philipp at weitershausen.de
Thu Jan 10 09:44:00 EST 2008

Martijn Faassen wrote:
> Godefroid Chapelle wrote:
> [snip]
>> Hmm, I have the feeling this is a problem we have seen at the 
>> beginning with Plone as well.
>> IIRC, this is a caching problem, kukit.js gets computed on each 
>> request  because cache headers are missing.
> Probably unrelated, but I was also wondering what Grok's caching story 
> currently is for things placed in the 'static' directory. Do we have a 
> way to control this caching at all?

Stuff in the 'static' dir are normal Zope3 resources. They set the 
Last-Modified headers automatically based on the file's modification 
time and know how to deal with a browser's If-Modified-Since request 
[1]. They also tell the browser that a file resource has a cache 
lifetime of one day (86400 s) via the Cache-Control header[2]. This 
value isn't easily customized.

[1] zope.app.publisher.fileresource.FileResource.GET
[2] zope.app.publisher.fileresource.setCacheControl

More information about the Grok-dev mailing list