X-Git-Url: https://git.cyclocoop.org/%242?a=blobdiff_plain;f=includes%2Fjob%2FJobQueueDB.php;h=4d0f294bc0478a7ab344d10c26f4418105b88dae;hb=2df4cb35478f9946b3538a8b0ddc86b2dfad2124;hp=7f3a73c3ae3541c9d265e039502c12a9b16e8664;hpb=78706fcf68cba798de4788a7f1f7a779672a0a50;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/job/JobQueueDB.php b/includes/job/JobQueueDB.php index 7f3a73c3ae..4d0f294bc0 100644 --- a/includes/job/JobQueueDB.php +++ b/includes/job/JobQueueDB.php @@ -49,8 +49,8 @@ class JobQueueDB extends JobQueue { return false; } - $found = $this->getSlaveDB()->selectField( - 'job', '1', array( 'job_cmd' => $this->type ), __METHOD__ + $found = $this->getSlaveDB()->selectField( // unclaimed job + 'job', '1', array( 'job_cmd' => $this->type, 'job_token' => '' ), __METHOD__ ); $wgMemc->add( $key, $found ? 'false' : 'true', self::CACHE_TTL ); @@ -59,6 +59,9 @@ class JobQueueDB extends JobQueue { /** * @see JobQueue::doBatchPush() + * @param array $jobs + * @param $flags + * @throws DBError|Exception * @return bool */ protected function doBatchPush( array $jobs, $flags ) { @@ -367,6 +370,8 @@ class JobQueueDB extends JobQueue { /** * @see JobQueue::doAck() + * @param Job $job + * @throws MWException * @return Job|bool */ protected function doAck( Job $job ) { @@ -386,6 +391,8 @@ class JobQueueDB extends JobQueue { /** * @see JobQueue::doDeduplicateRootJob() + * @param Job $job + * @throws MWException * @return bool */ protected function doDeduplicateRootJob( Job $job ) {