[tahoe-dev] 'Client' caching?
Kevin Reid
kpreid at mac.com
Thu Nov 26 11:39:11 PST 2009
On Nov 26, 2009, at 14:09, Brian Warner wrote:
>
> Hm, I'm surprised that didn't work. Do you know what caused Squid to
> believe the file was changing each time? Maybe a quick peek at the
> returned headers would be informative.
>
> Basically, any URL that starts with /uri/URI:CHK: should be
> immutable and an ideal choice for caching. We'd planned (although I
> can't check right now to see whether we got around to implementing
> it or not) to add an ETag: header with the file's UEB header, which
> is basically a hash of the contents, and thus an ideal etag. And I
> know we aren't intentionally adding any Cache-Control or date
> headers that might make the file look uncacheable.
FWIW,
http://redbot.org/?uri=http%3A%2F%2Ftahoe.soultcer.net%2Ffile%2FURI%253ACHK%253Aojen5pzrgtyuqad5bfjqrsc4g4%253Abi4k6tihvzq6lb6toiia6rtzyvsavgov3a4zljwty35up74xexfa%253A3%253A10%253A3228%2F%40%40named%3D%2Ftahoe-playground.html
says:
• This response can be stored by any cache.
• This response is stale.
• This response allows heuristic freshness to be used.
• This response can be served stale.
I'm no expert on HTTP caching but perhaps Squid requires "non-
heuristic freshness", (i.e. explicit expiration information?) before
it will cache anything.
It also says that "The Etag header's syntax isn't valid.", which is
true in that per the linked RFC the ETag ought to be quoted. But in my
experience Apache also generates the same sort of bad tag by default,
so.
--
Kevin Reid <http://switchb.org/kpreid/>
More information about the tahoe-dev
mailing list