From 7a4348640e09bea835620aceab88204c81e81012 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Tue, 20 Oct 2015 13:51:59 -0700 Subject: [PATCH] Make triggerOpportunisticLinksUpdate() directly use RefreshLinks This makes the jobs *actually* end up in the 'refreshLinksPrioritized' queue rather than 'refreshLinks'. These jobs can run fast in a higher priority queue since the output is already cached (much of the point of 'prioritize'). They won't if they get stuck behind regular 'refreshLinks'. This also avoids the indirection of an intermediate job. The use of lazyPush() is already enough to prevent the user from experiencing cross-DC RTT overhead. Change-Id: I5d0440588db09c299cd70191e5624ffc7ebf04c0 --- includes/page/WikiPage.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/includes/page/WikiPage.php b/includes/page/WikiPage.php index 29038c7e07..8acb3e3101 100644 --- a/includes/page/WikiPage.php +++ b/includes/page/WikiPage.php @@ -3489,11 +3489,7 @@ class WikiPage implements Page, IDBAccessObject { if ( $this->getLinksTimestamp() < $this->getTouched() ) { $params['isOpportunistic'] = true; $params['rootJobTimestamp'] = $parserOutput->getCacheTime(); - - JobQueueGroup::singleton()->lazyPush( EnqueueJob::newFromLocalJobs( - new JobSpecification( 'refreshLinks', $params, - array( 'removeDuplicates' => true ), $this->mTitle ) - ) ); + JobQueueGroup::singleton()->lazyPush( new RefreshLinksJob( $this->mTitle, $params ) ); } } -- 2.20.1