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

AO3-6890 Add puma worker killer gem #5038

Merged
merged 2 commits into from
Jan 29, 2025

Conversation

brianjaustin
Copy link
Member

@brianjaustin brianjaustin marked this pull request as ready for review January 28, 2025 20:48
@Bilka2
Copy link
Contributor

Bilka2 commented Jan 28, 2025

Based on the docs I think you might have to call PumaWorkerKiller.enable_rolling_restart somewhere (which would also have a built-in splay). zombocom/puma_worker_killer#4 / https://github.com/zombocom/puma_worker_killer?tab=readme-ov-file#attention also suggest not putting it in an initializer for rails (and putting into before_fork), not sure if that still applies these days (maybe you know better how Puma is started in staging/production)

@@ -0,0 +1,3 @@
PumaWorkerKiller.config do |config|
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need a before_fork hook, or a call to start? Would the gem be activated this way?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I'm pretty sure Bilka is right. Based on the docs (which I am having a little trouble following since there seem to be multiple paths to configuring it), we need to do this in Ansible instead. The linked PR (visible only to folks with read+ access to that repo) needs to do it instead, since we don't have config/puma.rb here

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was expecting to do it in the config/puma.rb

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I removed this file and moved it to Ansible's config/puma.rb in https://github.com/OTWSystems/ansible/pull/146

@redsummernight redsummernight merged commit 1b156f9 into otwcode:master Jan 29, 2025
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants