diff options
Diffstat (limited to 'includes/jobqueue/JobQueue.php')
-rw-r--r-- | includes/jobqueue/JobQueue.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/includes/jobqueue/JobQueue.php b/includes/jobqueue/JobQueue.php index 8fa670b7c018..449f63e27ad4 100644 --- a/includes/jobqueue/JobQueue.php +++ b/includes/jobqueue/JobQueue.php @@ -30,6 +30,7 @@ use Wikimedia\UUID\GlobalIdGenerator; * * @ingroup JobQueue * @since 1.21 + * @stable for subclassing */ abstract class JobQueue { /** @var string DB domain ID */ @@ -57,6 +58,8 @@ abstract class JobQueue { protected const ROOTJOB_TTL = 2419200; // integer; seconds to remember root jobs (28 days) /** + * @stable for calling + * * @param array $params * - type : A job type * - domain : A DB domain ID @@ -68,6 +71,7 @@ abstract class JobQueue { * - order : Queue order, one of ("fifo", "timestamp", "random") [default: variable] * - readOnlyReason : Mark the queue as read-only with this reason [default: false] * @throws JobQueueError + * */ protected function __construct( array $params ) { $this->domain = $params['domain'] ?? $params['wiki']; // b/c @@ -187,6 +191,7 @@ abstract class JobQueue { /** * Find out if delayed jobs are supported for configuration validation * + * @stable for overriding * @return bool Whether delayed jobs are supported */ protected function supportsDelayedJobs() { @@ -292,6 +297,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::getDelayedCount() * @return int */ @@ -315,6 +321,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::getAbandonedCount() * @return int */ @@ -478,6 +485,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::deduplicateRootJob() * @param IJobSpecification $job * @throws JobQueueError @@ -519,6 +527,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::isRootJobOldDuplicate() * @param IJobSpecification $job * @return bool @@ -569,6 +578,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::delete() * @throws JobQueueError */ @@ -589,6 +599,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::waitForBackups() * @return void */ @@ -605,6 +616,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::flushCaches() * @return void */ @@ -625,6 +637,7 @@ abstract class JobQueue { * Get an iterator to traverse over all delayed jobs in this queue. * Note: results may be stale if the queue is concurrently modified. * + * @stable for overriding * @return Iterator * @throws JobQueueError * @since 1.22 @@ -639,6 +652,7 @@ abstract class JobQueue { * Callers should be quick to iterator over it or few results * will be returned due to jobs being acknowledged and deleted * + * @stable for overriding * @return Iterator * @throws JobQueueError * @since 1.26 @@ -650,6 +664,7 @@ abstract class JobQueue { /** * Get an iterator to traverse over all abandoned jobs in this queue * + * @stable for overriding * @return Iterator * @throws JobQueueError * @since 1.25 @@ -661,6 +676,7 @@ abstract class JobQueue { /** * Do not use this function outside of JobQueue/JobQueueGroup * + * @stable for overriding * @return string * @since 1.22 */ @@ -682,6 +698,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::getSiblingQueuesWithJobs() * @param array $types List of queues types * @return array|null (list of queue types) or null if unsupported @@ -705,6 +722,7 @@ abstract class JobQueue { } /** + * @stable for overriding * @see JobQueue::getSiblingQueuesSize() * @param array $types List of queues types * @return array|null (list of queue types) or null if unsupported |