-
-
Notifications
You must be signed in to change notification settings - Fork 429
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
3.8.5 Possible regression in injecting tenant models into queued jobs #1260
Comments
This has been reported but I can't seem to reproduce the bug myself in a fresh Laravel 11 app. Will appreciate any testing. |
Hi, I do have this problem when queueing batches for one tenant (300-400 jobs) with a lot of data using laravel 10.48.22 and php 8.2.19 and on our test server with php 8.2.23. After 10 or so jobs it starts failing for the rest of them. For me reverting to tenancy 3.8.4 gets our environment running again. |
Job batches aren't supported in v3 (maybe the support is flaky rather than completely missing?). We've added a bootstrapper in v4 to address that. So it's possible that the < 3.8.5 behavior made them work in your case for some reason? Can you reproduce this using pure jobs without batches? |
I can confirm that it works when I just dispatch them immediately instead of batching them |
Bug description
The changes made in #1251 have made injecting tenant models into queued jobs not work again, as in older versions of v3.
Steps to reproduce
Inject a tenant-context model into a queued job.
Expected behavior
Should be supported.
Laravel version
any
stancl/tenancy version
3.8.5
The text was updated successfully, but these errors were encountered: