Last modified: 2011-03-13 18:05:45 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 9071 - wgSquidMaxage of 0 (zero) not allowed.
wgSquidMaxage of 0 (zero) not allowed.
Status: RESOLVED WONTFIX
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
unspecified
Other Linux
: Lowest normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-02-22 21:28 UTC by fredrik danerklint
Modified: 2011-03-13 18:05 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description fredrik danerklint 2007-02-22 21:28:11 UTC
if you put wqSquidMaxage in your Localsettings.php to zero, then you aren't able to cache pages in Squid. 

As it is now, you will get the header "Cache-Control: private, must-revalidate, max-age=0".

With my patch of one char, you get the following header "s-maxage=0, must-revalidate, max-age=0" which still allows 
Squid to cache the page after validateing the page with Mediawiki.

--- OutputPage.php      2007-02-22 22:09:20.054349784 +0100
+++ OutputPage.php.org  2007-02-21 03:20:31.000000000 +0100
@@ -477,7 +477,7 @@
                $wgRequest->response()->header( 'Vary: Accept-Encoding, Cookie' );
                if( !$this->uncacheableBecauseRequestvars() && $this->mEnableClientCache ) {
                        if( $wgUseSquid && ! isset( $_COOKIE[ini_get( 'session.name') ] ) &&
-                         ! $this->isPrintable() && $this->mSquidMaxage >= 0 )
+                         ! $this->isPrintable() && $this->mSquidMaxage != 0 )
                        {
                                if ( $wgUseESI ) {
                                        # We'll purge the proxy cache explicitly, but require end user agents
Comment 1 Andrew Garrett 2007-03-19 05:06:50 UTC
... Correct me if I'm wrong, but isn't this expected? I would assume that
setting $wgSquidMaxage = 0 would mean that you NEVER want ANYTHING cached...
which is what happens.

Why would you put $wgSquidMaxage = 0 if you wanted pages cached?
Comment 2 Chad H. 2009-07-29 17:33:42 UTC
Marking WONTFIX per comment #1.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links