[Twisted-web] Static.File and browser caching

Matt Feifarek matt.feifarek at gmail.com
Thu Mar 31 14:47:49 MST 2005


Static.File doesn't seem to support any of the cache features that
modern browsers use.

There are various HTTP headers that govern this, including Etag,
Cache-Control, Expires, etc. The Twisted server returns a
comparatively minimal set of headers (hit twistedmatrix.com and look
at the headers).

Also, as far as I can tell, a "good citizen" HTTPD changes the
response from a "200" to another response code that indicates "nothing
new here", under certain circumstances. OR, it lets the browser figure
that out... but it has to give the browser enough headers for it to do

Is there a subclass of Static.File somewhere in Twisted that supports
these features, or am I perhaps looking in the wrong place for this


More information about the Twisted-web mailing list