jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/378028 )
Change subject: Avoid per-title page_lang DB queries HTMLCacheUpdateJob
......................................................................
Avoid per-title page_lang DB queries HTMLCacheUpdateJob
Change-Id: Ie2fa64400f05d90e615bd8ff26225e197605d244
---
M includes/jobqueue/jobs/HTMLCacheUpdateJob.php
1 file changed, 5 insertions(+), 2 deletions(-)
Approvals:
Umherirrender: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
b/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
index 0aa33ca..e8edab5 100644
--- a/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
+++ b/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
@@ -103,7 +103,7 @@
* @param array $pages Map of (page ID => (namespace, DB key)) entries
*/
protected function invalidateTitles( array $pages ) {
- global $wgUpdateRowsPerQuery, $wgUseFileCache;
+ global $wgUpdateRowsPerQuery, $wgUseFileCache,
$wgPageLanguageUseDB;
// Get all page IDs in this query into an array
$pageIds = array_keys( $pages );
@@ -145,7 +145,10 @@
// Get the list of affected pages (races only mean something
else did the purge)
$titleArray = TitleArray::newFromResult( $dbw->select(
'page',
- [ 'page_namespace', 'page_title' ],
+ array_merge(
+ [ 'page_namespace', 'page_title' ],
+ $wgPageLanguageUseDB ? [ 'page_lang' ] : []
+ ),
[ 'page_id' => $pageIds, 'page_touched' =>
$dbw->timestamp( $touchTimestamp ) ],
__METHOD__
) );
--
To view, visit https://gerrit.wikimedia.org/r/378028
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ie2fa64400f05d90e615bd8ff26225e197605d244
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz <[email protected]>
Gerrit-Reviewer: Umherirrender <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits