- Issue created by @pwolanin
This can only be done when development of 12.x is open
follow-up to β¨ Track the number of times a queue item is claimed and pass as an optional param to queue workers Active
Add the new parameter to the QueueWorkerInterface
Original description:
When using e.g. the DelayedRequeue exception or when a queue item fails and is claimed again later because its lease expires we have no way of checking in the queue worker itself whether there is some recurring failure that might necessitate discarding the queue item or e.g. moving it to a dead letter queue.
This is not exactly the cron or batch systems, but related. Not seeing a component for queue system
Update the queue schema to support a column for the number of times an item has been claimed. Increment that number. Add an extension of the QueueWorkerInterface with a version of the processItem() methods that receives all the fields from the queue table except the data.
The proposed change should also resolve the 2 linked issues:
β¨
Cron queue workers should receive queued item creation data
Active
π
BatchQueue::claimItem() can get stuck with huge data in batch queue
Needs review
We could consider adding support in queue processing for something like an InvalidQueueItem exception that would log a message and remove the item from the queue, but the queue worker itself could log a message and return to just allow the item to be deleted.
For now, implement without adding support for a new exception type.
Review and validate changes
n/a
Possible new interface subclass
Add a column to the queue table
todo
Active
11.0 π₯
cron system