Skip to content

Commit

Permalink
Don’t raise an exception on SIGTERM
Browse files Browse the repository at this point in the history
Looking at our Rollbar quota, the large majority of the errors we get
there come from, I believe, the recurring Heroku restart that happens.
I see no reason to report these to Rollbar, since they are expected
and, at least while using Heroku, necessary.

Luckily, looks like [Puma has an option for this][0], so it makes sense
to me to turn it on (or rather off, since we’re setting it to `false`).
[Found it][1] while doing some research on this subject, since I’ve had
a feeling I’ve seen it before.

[0]: https://www.rubydoc.info/gems/puma/Puma%2FDSL:raise_exception_on_sigterm
[1]: puma/puma#1438
  • Loading branch information
gnclmorais committed Oct 16, 2022
1 parent 3b8f6eb commit 8372d22
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions config/puma.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
rackup DefaultRackup
port ENV['PORT'] || 3000
environment ENV['RACK_ENV'] || 'development'
raise_exception_on_sigterm false

on_worker_boot do
# worker specific setup
Expand Down

0 comments on commit 8372d22

Please sign in to comment.