From c748d9ce65e8883d629042afb46e567b687e70d2 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Wed, 31 Oct 2012 11:51:21 -0700 Subject: [PATCH] [JobQueue] Use "flush" option with commit(). Change-Id: If612f8e282c1aa7014461f8878aa9721b30eeb42 --- includes/job/JobQueueDB.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/includes/job/JobQueueDB.php b/includes/job/JobQueueDB.php index b850610e05..e9af92ac9c 100644 --- a/includes/job/JobQueueDB.php +++ b/includes/job/JobQueueDB.php @@ -279,10 +279,7 @@ class JobQueueDB extends JobQueue { */ protected function doAck( Job $job ) { $dbw = $this->getMasterDB(); - if ( $dbw->trxLevel() ) { - wfWarn( "Attempted to ack a job in a transaction; committing first." ); - $dbw->commit(); // push existing transaction - } + $dbw->commit( __METHOD__, 'flush' ); // flush existing transaction $autoTrx = $dbw->getFlag( DBO_TRX ); // automatic begin() enabled? $dbw->clearFlag( DBO_TRX ); // make each query its own transaction -- 2.20.1