Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
out_of_band hook not working when using multiple threads #2177
Describe the bug
Now, to show it works with
I see. So, if we provide a feature in Puma, it should obviously work, and this definitely doesn't, so I want to fix that.
However, OOBGC is an outdated technique since the changes introduced in the Ruby 2.3 GC. I can't recommend it. GitHub disabled it after they realized it was causing an additional 10% CPU usage.
I contributed the PR #1648 that implemented the
My use-case for this feature has also been OOBGC, here are my previous comments on the topic #450 (comment):
After looking at this more closely, it does look like the OOB hook never worked in any configuration with threads > 1. (It's been running in my production workload, but on a fork from which I've extracted various feature PRs, and I should have tested/verified the extracted out-of-band PR more thoroughly. Sorry!)
I added my own attempt at a fix to #2218, which also includes a couple of tests.