Skip to content

Commit

Permalink
Fix requeued jobs sometimes marking as failed in job status until res…
Browse files Browse the repository at this point in the history
…tarted

If we don't clear currentJob from checkForRequeuedJob, then in unregisterWorker we are marking the status as failed.  The status would be fixed when we ended up starting the job, but if we were watching for the status it would briefly show the wrong status.
  • Loading branch information
daneren2005 committed Oct 12, 2021
1 parent 0c2b76c commit 30857ad
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/Resque/Worker.php
Original file line number Diff line number Diff line change
Expand Up @@ -529,6 +529,7 @@ protected function checkForRequeueJob() {
if(!Resque::redis()->ping()) {
$this->logger->log(Psr\Log\LogLevel::EMERGENCY, 'Redis instance is not active!');
}
$this->currentJob = null;
}
}

Expand Down

0 comments on commit 30857ad

Please sign in to comment.