Merge "Do not retry the ThumbnailRenderJob."
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Thu, 11 Oct 2018 18:32:40 +0000 (18:32 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Thu, 11 Oct 2018 18:32:40 +0000 (18:32 +0000)
includes/jobqueue/jobs/ThumbnailRenderJob.php

index f87a336..63575eb 100644 (file)
@@ -134,4 +134,16 @@ class ThumbnailRenderJob extends Job {
                }
                return false;
        }
+
+       /**
+        * Whether to retry the job.
+        * @return bool
+        */
+       public function allowRetries() {
+               // ThumbnailRenderJob is a warmup for the thumbnails cache,
+               // so loosing it is not a problem. Most times the job fails
+               // for non-renderable or missing images which will not be fixed
+               // by a retry, but will create additional load on the renderer.
+               return false;
+       }
 }