Created attachment 22086 [details] A handler to provide cache purge operation A simple minded cache purge. 1) does not understand variants. 2) takes input as a post request with a number of URLs one per line 3) generates our own request, so should be possible to add vary & headers configuration ------------- <Location /cache> SetHandler meta_cache </Location> invoke e.g $cat > url.file /index.html http://webproxy.india.sun.com/index.html ^D $wget --post-file url.file 'http://agneyam.india.sun.com:8080/cache?purge'
Thanks for the patch, but aren't you doing rather too much work here? (1) Why wouldn't a normal subrequest serve for your fake_request? (2) How about mod_request vs your process_post? Hmmm, OK, I think that's a limitation of mod_request rather than of your patch. More importantly, you're touching private parts of mod_cache. That's liable to break at any time. If you can't get what you need from the public API, that's a subject that should be raised on the dev@ list. As it stands, it's something between a patch and a module. Also more fundamental: what protocols does your module implement? I'm not sure what web caching protocols are relevant in the real world (e.g. compatibility with squid would be a plus), but folks on dev@ might know better.
From what I can see, I don't see what PURGE does that isn't already done by a GET with a "Cache-Control: no-cache" header (to refresh) or "no-store" header (to purge) in the request? I suspect what is being attempted here is already offered out the box by RFC2616.
htcacheclean in httpd-trunk includes the capability to purge cache entries from the command line: htcacheclean -p /path/to/my/cache http://delete.me/? Resolving as fixed for now, as we have means to purge entries in the cache via RFC2616, and (in trunk) via the command line.
Undo spam change