From 78a654eddc10df5c64cadd2f187e889f3fd4176e Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Thu, 5 Jun 2014 15:21:32 -0700 Subject: [PATCH] Made pool counter better handled nested calls * This is useful for the "GetLocalFileCopy" pool for example. Change-Id: Ie9f092fb595d12ebc6548571cecbd2f4251297db --- includes/poolcounter/PoolCounterWork.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/includes/poolcounter/PoolCounterWork.php b/includes/poolcounter/PoolCounterWork.php index 523e9e0194..1bc1a8b122 100644 --- a/includes/poolcounter/PoolCounterWork.php +++ b/includes/poolcounter/PoolCounterWork.php @@ -112,6 +112,10 @@ abstract class PoolCounterWork { } switch ( $status->value ) { + case PoolCounter::LOCK_HELD: + // Better to ignore nesting pool counter limits than to fail. + // Assume that the outer pool limiting is reasonable enough. + /* no break */ case PoolCounter::LOCKED: $result = $this->doWork(); $this->poolCounter->release(); -- 2.20.1