Anders Nordby wrote:

Hi,

I would like to cache requests for Shockwave Flash files. The problem
is, these files have a bunch of cgi/query parameters that is changed for
every request, making Squid fetch them from the web server each time.
The output from the webserver is the same each time, so there's no real
reason why one shouldn't cache or be able to cache the files. An
example (had to turn off strip_query_terms to see it in the log):

1095077099.840     25 195.159.125.115 TCP_MISS/200 15910 GET
http://ap.oasfile.aftenposten.no/ap/rosaindex/768x50_aftenposten.swf?clickTAG1=http%3A//primetime.ad.primetime.net/RealMedia/ads/click_lx.ads/www.aftenposten.no/forside/5278/Top1/primetime/ap_rosaindex_768x50_til_des04/rosaindex_2xclicktag.html/63333966376437333430336565663130%3F_RM_REDIR_%3Dhttp%3A//www.rosaindex.no/%3Frsat%3D3&clickTAG2=http%3A//primetime.ad.primetime.net/RealMedia/ads/click_lx.ads/www.aftenposten.no/forside/5278/Top1/primetime/ap_rosaindex_768x50_til_des04/rosaindex_2xclicktag.html/63333966376437333430336565663130%3Fhttp%3A//www.rosaindex.no/%3Fsaction%3DSOK%26fdsc%3DrsCompany%26rsat%3D2
- DIRECT/127.0.0.1 application/x-shockwave-flash

The actual file is just served statically from a local thttpd that has
all the files.

I suppose the Shockwave "program" (the swf file) uses the query
parameters as a runtime configuration for what to do etc., so if only
Squid could pass this on and still cache the file contents, that would
be exactly what I want.

Anyone have ideas about this? Is it doable? Running the swf's through
Squid works, it's just that every file that has query parameters is not
cached. :-(

Regards,



By default, squid don't make cache of dynamic content:

acl QUERY urlpath_regex cgi-bin \?
no_cache deny QUERY


If you want cached the swf's, then remove the query parameter from the QUERY acl, but it isn't recommended. See: http://www.mnot.net/cache_docs/

Emilio C.





Reply via email to