Documentation

AbstractAdapter
in package
implements AdapterInterface

AbstractYes

Adapter abstract class

Tags
category

Pop

author

Nick Sagona, III nick@popphp.org

copyright

Copyright (c) 2009-2026 Nick Sagona, III

license

https://www.popphp.org/license New BSD License

version
3.0.0

Table of Contents

Interfaces

AdapterInterface
Adapter interface

Properties

$priority  : string
Queue priority

Methods

__construct()  : mixed
Constructor
bury()  : AdapterInterface
Move a job to the dead-letter store (terminal)
clear()  : AdapterInterface
Clear pending and reserved jobs (not dead-letter jobs)
clearDead()  : AdapterInterface
count()  : int
Count of pending + reserved jobs
countDead()  : int
delete()  : AdapterInterface
Permanently remove a job (success/ack)
deleteDeadJob()  : AdapterInterface
getDeadJob()  : mixed
getDeadJobs()  : array<string|int, mixed>
getPriority()  : string
hasDeadJobs()  : bool
hasJobs()  : bool
Whether there are pending or reserved jobs
isFifo()  : bool
isFilo()  : bool
isLifo()  : bool
isLilo()  : bool
push()  : AdapterInterface
Push a job onto the queue
release()  : AdapterInterface
Put a reserved job back to pending. $delay overrides the job's own backoff schedule when given; otherwise release() computes the delay from $job->getBackoffDelay().
reserve()  : AbstractJob|null
Atomically claim the next eligible job and lease it. Returns null if nothing is eligible (no pending jobs due, or all reserved jobs have a live lease).
retryDeadJob()  : AdapterInterface
Move a dead-letter job back to pending
setPriority()  : AbstractAdapter

Properties

Methods

__construct()

Constructor

public __construct([string|null $priority = null ]) : mixed
Parameters
$priority : string|null = null

count()

Count of pending + reserved jobs

public abstract count() : int
Return values
int

getDeadJob()

public abstract getDeadJob(string $jobId[, bool $unserialize = true ]) : mixed
Parameters
$jobId : string
$unserialize : bool = true

getDeadJobs()

public abstract getDeadJobs([bool $unserialize = true ]) : array<string|int, mixed>
Parameters
$unserialize : bool = true
Return values
array<string|int, mixed>

hasDeadJobs()

public abstract hasDeadJobs() : bool
Return values
bool

hasJobs()

Whether there are pending or reserved jobs

public abstract hasJobs() : bool
Return values
bool

release()

Put a reserved job back to pending. $delay overrides the job's own backoff schedule when given; otherwise release() computes the delay from $job->getBackoffDelay().

public abstract release(AbstractJob $job[, int|null $delay = null ]) : AdapterInterface
Parameters
$job : AbstractJob
$delay : int|null = null
Return values
AdapterInterface

reserve()

Atomically claim the next eligible job and lease it. Returns null if nothing is eligible (no pending jobs due, or all reserved jobs have a live lease).

public abstract reserve() : AbstractJob|null
Return values
AbstractJob|null

        
On this page

Search results