From: Rob Church
Date: Sun, 24 Dec 2006 08:58:05 +0000 (+0000)
Subject: Remove old unused watchlist cache (leftover from old schema)
X-Git-Tag: 1.31.0-rc.0~54778
X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=8a2c2ba0349d294a83bc5ae025d5bcb0537370e0;p=lhc%2Fweb%2Fwiklou.git
Remove old unused watchlist cache (leftover from old schema)
---
diff --git a/RELEASE-NOTES b/RELEASE-NOTES
index 70be248250..f727b8b427 100644
--- a/RELEASE-NOTES
+++ b/RELEASE-NOTES
@@ -405,6 +405,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
* (bug 6853) Use a checkbox on the installer form to indicate that a superuser
account should be used; this is clearer than the old check which relied on
the password never being an obscure value
+* Remove old unused watchlist cache, which was a leftover from the old schema
+ where watchlists were more expensive to generate
== Languages updated ==
diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php
index 3778bc197a..49e536d020 100644
--- a/includes/DefaultSettings.php
+++ b/includes/DefaultSettings.php
@@ -1188,10 +1188,6 @@ $wgMiserMode = false;
$wgDisableQueryPages = false;
/** Number of rows to cache in 'querycache' table when miser mode is on */
$wgQueryCacheLimit = 1000;
-/** Generate a watchlist once every hour or so */
-$wgUseWatchlistCache = false;
-/** The hour or so mentioned above */
-$wgWLCacheTimeout = 3600;
/** Number of links to a page required before it is deemed "wanted" */
$wgWantedPagesThreshold = 1;
/** Enable slow parser functions */
diff --git a/includes/SpecialWatchlist.php b/includes/SpecialWatchlist.php
index f149bcbbff..1f75a8da3f 100644
--- a/includes/SpecialWatchlist.php
+++ b/includes/SpecialWatchlist.php
@@ -12,12 +12,11 @@ require_once( 'SpecialRecentchanges.php' );
/**
* Constructor
- * @todo Document $par parameter.
- * @param $par String: FIXME
+ *
+ * @param $par Parameter passed to the page
*/
function wfSpecialWatchlist( $par ) {
global $wgUser, $wgOut, $wgLang, $wgMemc, $wgRequest, $wgContLang;
- global $wgUseWatchlistCache, $wgWLCacheTimeout;
global $wgRCShowWatchingUsers, $wgEnotifWatchlist, $wgShowUpdatedMarker;
global $wgEnotifWatchlist;
$fname = 'wfSpecialWatchlist';
@@ -102,16 +101,6 @@ function wfSpecialWatchlist( $par ) {
$wgOut->addHTML( "
\n" . wfMsg( 'wldone' ) . "
\n" );
}
- if ( $wgUseWatchlistCache ) {
- $memckey = wfMemcKey( 'watchlist', 'id', $wgUser->getId() );
- $cache_s = @$wgMemc->get( $memckey );
- if( $cache_s ){
- $wgOut->addWikiText( wfMsg('wlsaved') );
- $wgOut->addHTML( $cache_s );
- return;
- }
- }
-
$dbr =& wfGetDB( DB_SLAVE );
list( $page, $watchlist, $recentchanges ) = $dbr->tableNamesN( 'page', 'watchlist', 'recentchanges' );
@@ -384,10 +373,6 @@ function wfSpecialWatchlist( $par ) {
$dbr->freeResult( $res );
$wgOut->addHTML( $s );
- if ( $wgUseWatchlistCache ) {
- $wgMemc->set( $memckey, $s, $wgWLCacheTimeout);
- }
-
}
function wlHoursLink( $h, $page, $options = array() ) {