httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Allan Edwards <a...@us.ibm.com>
Subject mod_cache & forward proxy
Date Wed, 05 Mar 2003 22:23:27 GMT
Currently "CachEnable foo / " will configure mod_cache to cache all forward proxy
responses. Seems to me we want to be a little more granular than that.
The following patch will enable the use of e.g. "CacheEnable foo http: "
to signify that just HTTP content should be cached. It also will allow
scoping to a particular server e.g. "CacheEnable foo http://CacheOnlyThisServer/ "
which is useful for say a branch office proxy, where you want to cache content
from just the corporate server. Does this sound like a good idea? It will
of course break current forward proxy config files that are using "CacheEnable foo / ",
but mod_cache *is* still experimental.

Index: mod_cache.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/experimental/mod_cache.c,v
retrieving revision 1.73
diff -u -d -b -r1.73 mod_cache.c
--- mod_cache.c	3 Feb 2003 17:52:59 -0000	1.73
+++ mod_cache.c	5 Mar 2003 18:52:13 -0000
@@ -95,7 +95,7 @@
      apr_uri_t uri = r->parsed_uri;
      char *url = r->unparsed_uri;
      apr_size_t urllen;
-    char *path = uri.path;
+    char *path = r->uri;
      const char *types;
      cache_info *info = NULL;
      cache_request_rec *cache;

Also, anyone have a good reason why we can't remove these
lines and allow mod_cache to serve default welcome pages?

     /* DECLINE urls ending in / ??? EGP: why? */
     if (url[urllen-1] == '/') {
         return DECLINED;
     }

Allan




Mime
View raw message