-
-
Notifications
You must be signed in to change notification settings - Fork 208
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
Freezes puma on code change #95
Comments
I got a big fat stack of backtraces via sigdump. Here's my puma thread trying to unload:
It seems to be competing with several good job schedulers:
|
It looks like this is too broad: good_job/lib/good_job/scheduler.rb Lines 140 to 144 in ccff9a1
It should not be wrapping until the future is fulfilled. Otherwise it goes to sleep holding the lock and prevents any critical exclusive sections from running, i.e. deadlocks. |
... I'm not even sure you should be using https://github.com/rails/rails/blob/master/activejob/lib/active_job/railtie.rb#L41-L45 |
Here too — going to sleep ( good_job/lib/good_job/notifier.rb Lines 72 to 105 in ccff9a1
|
Thanks @sj26 for digging into this. This is great work ✨ I did a lot of deadlock tracing when #82 landed, there's additional debugging documentation there. To dig into your comments:
I'm fairly certain the long-running Is this something you'd be able to dig into more deeply? If you have the time for synchronous work, I really like pair-programming and could host a zoom/tuple. |
Nice, I'll read through that a little more closely soon. And re: pairing, I'm just about to head off for the night, but another time for sure. For now, I think you want something a little more like this — explicitly managing ActiveRecord connection pool usage a la ActionCable, without being trapped by the |
When running GoodJob async in a puma process, if I save a file on the filesystem and then make a new puma request then the whole process locks up irrecoverably, and I have to
kill -9
the process. I'm using Rails 6.0.3.2, puma 4.3.5 and good_job 1.2.1, in the default configuration, i.e with zeitwerk and listen, on macOS.The text was updated successfully, but these errors were encountered: