[JobQueue] Allow certain job types to always opt out of retries.
[lhc/web/wiklou.git] / includes / job / Job.php
index 24e9093..9ec58c9 100644 (file)
@@ -177,12 +177,19 @@ abstract class Job {
        }
 
        /**
-        * @return bool
+        * @return bool Whether only one of each identical set of jobs should be run
         */
        public function ignoreDuplicates() {
                return $this->removeDuplicates;
        }
 
+       /**
+        * @return bool Whether this job can be retried on failure by job runners
+        */
+       public function allowRetries() {
+               return true;
+       }
+
        /**
         * Subclasses may need to override this to make duplication detection work
         *