Chad has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/182138

Change subject: Remove LinksUpdateSecondary jobs
......................................................................

Remove LinksUpdateSecondary jobs

Long since deprecated and drained from queues.

Change-Id: Ib1805f6b6abb190d94dbc05fb31b586a8449468b
---
M CirrusSearch.php
D includes/Job/LinksUpdateSecondary.php
M tests/jenkins/Jenkins.php
3 files changed, 0 insertions(+), 50 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CirrusSearch 
refs/changes/38/182138/1

diff --git a/CirrusSearch.php b/CirrusSearch.php
index d7c7ce6..588b866 100644
--- a/CirrusSearch.php
+++ b/CirrusSearch.php
@@ -572,7 +572,6 @@
 $wgAutoloadClasses['CirrusSearch\Job\DeletePages'] = $jobsDir . 
'DeletePages.php';
 $wgAutoloadClasses['CirrusSearch\Job\IncomingLinkCount'] = $jobsDir . 
'IncomingLinkCount.php';
 $wgAutoloadClasses['CirrusSearch\Job\LinksUpdate'] = $jobsDir . 
'LinksUpdate.php';
-$wgAutoloadClasses['CirrusSearch\Job\LinksUpdateSecondary'] = $jobsDir . 
'LinksUpdateSecondary.php';
 $wgAutoloadClasses['CirrusSearch\Job\MassIndex'] = $jobsDir . 'MassIndex.php';
 $wgAutoloadClasses['CirrusSearch\Job\OtherIndex'] = $jobsDir . 
'OtherIndex.php';
 $wgAutoloadClasses['CirrusSearch\Maintenance\AnalysisConfigBuilder'] = 
$maintenanceDir . 'AnalysisConfigBuilder.php';
@@ -648,7 +647,6 @@
 $wgJobClasses[ 'cirrusSearchIncomingLinkCount' ] = 
'CirrusSearch\Job\IncomingLinkCount';
 $wgJobClasses[ 'cirrusSearchLinksUpdate' ] = 'CirrusSearch\Job\LinksUpdate';
 $wgJobClasses[ 'cirrusSearchLinksUpdatePrioritized' ] = 
'CirrusSearch\Job\LinksUpdate';
-$wgJobClasses[ 'cirrusSearchLinksUpdateSecondary' ] = 
'CirrusSearch\Job\LinksUpdateSecondary';
 $wgJobClasses[ 'cirrusSearchMassIndex' ] = 'CirrusSearch\Job\MassIndex';
 $wgJobClasses[ 'cirrusSearchOtherIndex' ] = 'CirrusSearch\Job\OtherIndex';
 
diff --git a/includes/Job/LinksUpdateSecondary.php 
b/includes/Job/LinksUpdateSecondary.php
deleted file mode 100644
index c6ef277..0000000
--- a/includes/Job/LinksUpdateSecondary.php
+++ /dev/null
@@ -1,47 +0,0 @@
-<?php
-
-namespace CirrusSearch\Job;
-
-use \JobQueueGroup;
-use \Title;
-
-/**
- * Tombstone job to convert currently queued jobs into the new
- * IncomingLinkCount job type.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- * http://www.gnu.org/copyleft/gpl.html
- */
-class LinksUpdateSecondary extends Job {
-       public function __construct( $title, $params ) {
-               parent::__construct( $title, $params );
-               // TODO Remove this job when it has drained from the queues
-       }
-
-       protected function doJob() {
-               $titleKeys = array_merge( $this->params[ 'addedLinks' ],
-                       $this->params[ 'removedLinks' ] );
-               foreach ( $titleKeys as $titleKey ) {
-                       $title = Title::newFromDBKey( $titleKey );
-                       if ( !$title ) {
-                               continue;
-                       }
-                       $linkCount = new IncomingLinkCount( $title, array() );
-                       JobQueueGroup::singleton()->push( $linkCount );
-               }
-
-               return true;
-       }
-}
diff --git a/tests/jenkins/Jenkins.php b/tests/jenkins/Jenkins.php
index 6933da6..0b1a11f 100644
--- a/tests/jenkins/Jenkins.php
+++ b/tests/jenkins/Jenkins.php
@@ -102,7 +102,6 @@
        public static function recyclePruneAndUndelayJobs( $special, $subpage ) 
{
                $jobsToUndelay = array(
                        'cirrusSearchIncomingLinkCount',
-                       'cirrusSearchLinksUpdateSecondary',
                        'cirrusSearchLinksUpdate',
                        'cirrusSearchLinksUpdatePrioritized'
                );

-- 
To view, visit https://gerrit.wikimedia.org/r/182138
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib1805f6b6abb190d94dbc05fb31b586a8449468b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CirrusSearch
Gerrit-Branch: master
Gerrit-Owner: Chad <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to