[2.x] Add getPausedQueues() to QueueFactory for illuminate/queue v13.11+ compatibility#4673
Merged
Conversation
Contributor
|
Should reference this issue #4671 |
imorland
requested changes
May 26, 2026
imorland
left a comment
Member
There was a problem hiding this comment.
Thank you for this. The composer.json at the root of the repo should also be updated accordingly please.
As for your question on pausing support, yes I do think this should be supported in the future - I've also been thinking about a refactor of the Flarum queue implementation recently. It might be something we can do for 2.1+ in a non-breaking way, but equally it might have to wait for 3.0, depending on all the changes required
Contributor
Author
|
@imorland @huoxin233 Updated — also bumped |
luceos
approved these changes
May 26, 2026
imorland
approved these changes
May 26, 2026
imorland
added a commit
that referenced
this pull request
Jun 2, 2026
…4683) Flarum's QueueFactory stands in for Illuminate's full QueueManager, but only implemented part of the manager-level Queue Pause/Resume API. Each Illuminate release that wires up another pause method on the worker has crashed the queue with "Call to undefined method" — first isPaused(), then getPausedQueues() (#4673) — silently breaking queued notifications and mail. Stub the whole family as no-ops so the worker can't crash on the next addition: - Add pause(), pauseFor(), resume() and withoutInterruptionPolling(). - Fix getPausedQueues() to take ($connection, $queues), matching the QueueManager contract and the Worker's actual call (it previously only worked because PHP drops extra positional arguments). Queue pausing itself remains unsupported for now; it is planned for a future Flarum version.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #4671
Replaces #4672, which was based on the wrong branch.
illuminate/queue added getPausedQueues() to queue drivers in November 2025 as part of the Queue Pause/Resume feature — laravel/framework#57800.
In v13.11, Worker.php began calling this method on all queue factories — including Flarum's custom QueueFactory, which doesn't implement it, causing the queue worker to crash with «Call to undefined method» and breaking all queued notifications and mail silently.
Changes proposed in this pull request:
getPausedQueues(): arraytoQueueFactorywith a no-op implementation, consistent with the existingisPaused()pattern.illuminate/queueconstraint to^13.11incomposer.json.Reviewers should focus on:
Whether returning an empty array is the correct behaviour, or if Flarum should implement actual queue pausing support in the future.