httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua Slive" <jos...@slive.ca>
Subject Re: [users@httpd] Cache configuration advice
Date Fri, 02 May 2008 16:36:27 GMT
On Fri, May 2, 2008 at 6:22 AM, Marko Asplund <marko.asplund@ixonos.com> wrote:
>
>  On Wed, 30 Apr 2008 18:37:35 Joshua Slive wrote:
>
>  > >  As far as I've understood the below setup would not correctly cache
>  > >  request content when using request parameters (requires Expires header).
>  > >  What would be the best way to fix this?
>  >
>  > See the CacheIgnoreQueryString directive.
>
>  So, is the only way to get content for both of the below requests cached
>  correctly to make the backend system set the Expires header and setting
>  'CacheIgnoreQueryString Off' in httpd.conf?
>
>  /listnews?page=1
>  /listnews?page=2

No, if the response includes an appropriate Cache-Control/Expires
header, then the CacheIgnoreQueryString should not be necessary.

>  > You'll want to use the CacheDefaultExpire directive to control the
>  > local cache. Unfortunately, I don't think it is possible to set
>  > different expiration times within the same host, since this directive
>  > can't be placed in <Directory>/<Location> sections.
>
>  Yes, I found this out the hard way :(
>  Any hope of getting this restriction removed some time in the future?

The problem is that the cache operates somewhat outside the normal
apache configuration process. This is necessary to get maximum
efficiency (so that all the config directives don't need to be
processed on cached requests) but obviously limits configuration
flexibility. But if you manage to set correct Cache-Control headers on
your content, the CacheDefaultExpire directive should never come into
play, so you should be alright.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message