-
Notifications
You must be signed in to change notification settings - Fork 182
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
use Task instead of spawn_link for starting workers #436
use Task instead of spawn_link for starting workers #436
Conversation
Existing
New
From limited testing, this also introduces a crash report as well (assuming handle_sasl_reports is set to true). I will try to verify if there are any other changes introduced by it. |
Thanks for the quick response! I should have better described the potential changes. The list of behaviors for processes started through proc_lib is here: https://erlang.org/doc/man/proc_lib.html#description. SASL is mentioned, though it was deprecated with the release of OTP 21, so my hope is the impact of that is more limited. |
Thanks for PR @mitchellhenke!! @ananthakumaran let me know when we should cut a release. |
Hello! 👋🏼
I maintain https://github.com/getsentry/sentry-elixir and have received issues where failed jobs in Exq don't report process metadata from the crashed process (getsentry/sentry-elixir#349). It looks like it's due to using
spawn_link
instead of Elixir modules like Task or GenServer that rely on:proc_lib
underneath. The change would allow for some more detailed reporting on the state of the worker process is in when it crashed, including parent process, metadata, and more.I wasn't sure if
Task
was appropriate, but the tests do pass 🙂