Skip to content

Tags: AppsDevTeam/background-queue

Tags

v5.5.1

Toggle v5.5.1's commit message
Order background jobs by ID for consistent processing

Ensures jobs are processed in a predictable and consistent order, preventing potential starvation of older jobs.

v5.5.0

Toggle v5.5.0's commit message
Allow dynamic AMQP arguments based on queue name

Introduces an optional `queueArguments` parameter to the `Manager` constructor. This enables applying specific AMQP arguments, such as `x-single-active-consumer`, to queues whose names contain a defined string.

This provides more granular and flexible control over queue behavior without requiring separate queue parameter definitions for each unique configuration.

v5.4.4

Toggle v5.4.4's commit message
Handle deadlocks in job coalescing

The `markCoalescedJobsRedundant` operation can encounter transient database deadlocks (1213) during concurrent writes. This could leave jobs stuck in a PROCESSING state.

This change adds a retry mechanism with a back-off delay for the coalesce UPDATE to overcome these transient deadlocks. Additionally, a new index `(serial_group, coalesce_threshold)` is added to optimize the WHERE clause, reducing lock contention and preventing deadlocks by allowing targeted index scans.

v5.4.3

Toggle v5.4.3's commit message
Lower background queue job fetch limit

Reduces the maximum number of background jobs fetched and processed
per iteration from 10,000 to 1,000.

While the previous increase to 10,000 aimed to reduce database round-trips,
processing such a large batch concurrently could still lead to excessive
memory consumption for specific job types, resulting in out-of-memory
errors. This adjustment provides a better balance between database
efficiency and peak memory usage during job execution.

v5.4.2

Toggle v5.4.2's commit message
Implement job coalescing for background queue

Allows jobs to mark overlapping, unstarted jobs within the same serial group as REDUNDANT.

This prevents redundant processing, for example, when a "recalculate from X" job covers the work of later "recalculate from Y (where Y >= X)" jobs.

v5.4.1

Toggle v5.4.1's commit message
Improve memory handling for background queue processing

Addresses potential out-of-memory errors when processing a large number of background jobs.

*   Limits the number of background jobs fetched per iteration to 10,000.
*   Increases the PHP memory limit for the console `process` command to 1GB.

v5.4

Toggle v5.4's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Merge pull request #61 from AppsDevTeam/priority-and-serialgroup

Priority and serialgroup

v5.3.2

Toggle v5.3.2's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Update composer.json

v5.3.1

Toggle v5.3.1's commit message
Merge branch 'processWaitingJobs'

v5.3

Toggle v5.3's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Merge pull request #59 from AppsDevTeam/processWaitingJobs

Process waiting jobs