Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[11.x] Consider after_commit config in SyncQueue #51071

Merged

Conversation

hansnn
Copy link
Contributor

@hansnn hansnn commented Apr 15, 2024

AfterCommit support was added to the SyncQueue in #48860. However, it only works if the job in question implements the ShouldQueueAfterCommit interface or sets the afterCommit property - it does not work if after_commit is set to true in the sync driver's configuration. This makes the behavior inconsistent, which is what this PR intends to solve.

I spent some time unsuccessfully trying to figure out how to write a test for this. If anyone has an idea, please let me know and I'll add a test.

hansnn and others added 3 commits April 15, 2024 20:11
AfterCommit support was added to the SyncQueue in laravel#48860. However, it only works if the job in question implements the ShouldQueueAfterCommit interface or sets the afterCommit property - it does not work if after_commit is set to true in the sync driver's configuration. This makes the behavior inconsistent, which is what this commit solves by also considering the after_commit config.
@taylorotwell taylorotwell merged commit 50a9491 into laravel:11.x Apr 15, 2024
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants