From fe6498d7d2c926a3cf7d907a743ba8bb881351a3 Mon Sep 17 00:00:00 2001 From: daniel Date: Mon, 11 Feb 2013 20:40:12 +0100 Subject: [PATCH] Set timeout for Sites object in memcached. Change-Id: I8964a03c5989b368e0da07b42db463cf6e732fb3 --- includes/site/SiteSQLStore.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/includes/site/SiteSQLStore.php b/includes/site/SiteSQLStore.php index c46205736e..412380550f 100644 --- a/includes/site/SiteSQLStore.php +++ b/includes/site/SiteSQLStore.php @@ -47,6 +47,11 @@ class SiteSQLStore implements SiteStore { */ private $cacheKey = null; + /** + * @var int + */ + private $cacheTimeout = 3600; + /** * @since 1.21 * @@ -218,7 +223,7 @@ class SiteSQLStore implements SiteStore { } $cache = wfGetMainCache(); - $cache->set( $this->getCacheKey(), $this->sites ); + $cache->set( $this->getCacheKey(), $this->sites, $this->cacheTimeout ); wfProfileOut( __METHOD__ ); } -- 2.20.1