De-duplicate refreshLinks2 base jobs on insert.
authorAaron Schulz <aschulz@wikimedia.org>
Fri, 24 May 2013 18:46:56 +0000 (11:46 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Fri, 24 May 2013 18:48:15 +0000 (18:48 +0000)
* This should work better and take up less space than using root job
  de-duplication alone.

Change-Id: Ie339ccf0eed93f5d525a24519d20811de8f6c0b5

includes/job/jobs/RefreshLinksJob.php

index e9f017b..563ce2f 100644 (file)
@@ -112,6 +112,8 @@ class RefreshLinksJob extends Job {
 class RefreshLinksJob2 extends Job {
        function __construct( $title, $params, $id = 0 ) {
                parent::__construct( 'refreshLinks2', $title, $params, $id );
+               // Base jobs for large templates can easily be de-duplicated
+               $this->removeDuplicates = !isset( $params['start'] ) && !isset( $params['end'] );
        }
 
        /**