From e4ff67e0db7415322b7576a6439b31b9dd08a781 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Wed, 19 Nov 2014 11:22:03 -0800 Subject: [PATCH] Handle missing parser cache keys better in pool counter Change-Id: I493fd1ee5e9ab6c3a49a7f478460cbfe54393ca0 --- includes/poolcounter/PoolWorkArticleView.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/poolcounter/PoolWorkArticleView.php b/includes/poolcounter/PoolWorkArticleView.php index 5e7e39129a..da20f94159 100644 --- a/includes/poolcounter/PoolWorkArticleView.php +++ b/includes/poolcounter/PoolWorkArticleView.php @@ -67,7 +67,8 @@ class PoolWorkArticleView extends PoolCounterWork { $this->parserOptions = $parserOptions; $this->content = $content; $this->cacheKey = ParserCache::singleton()->getKey( $page, $parserOptions ); - parent::__construct( 'ArticleView', $this->cacheKey . ':revid:' . $revid ); + $keyPrefix = $this->cacheKey ?: wfMemcKey( 'articleview', 'missingcachekey' ); + parent::__construct( 'ArticleView', $keyPrefix . ':revid:' . $revid ); } /** -- 2.20.1