Ignore closed-terminal log errors in Puma plugin shutdown#741
Open
afurm wants to merge 1 commit intorails:mainfrom
Open
Ignore closed-terminal log errors in Puma plugin shutdown#741afurm wants to merge 1 commit intorails:mainfrom
afurm wants to merge 1 commit intorails:mainfrom
Conversation
Author
|
I saw the I tried to reproduce the exact matrix and seed locally: BUNDLE_GEMFILE=$PWD/gemfiles/rails_8_1.gemfile TARGET_DB=sqlite RBENV_VERSION=3.4.4 bundle exec ruby -Itest test/integration/recurring_tasks_test.rb --seed 33880
BUNDLE_GEMFILE=$PWD/gemfiles/rails_8_1.gemfile TARGET_DB=sqlite RBENV_VERSION=3.4.4 bundle exec bin/rails test --seed 33880Both passed locally. The full suite result was 230 runs, 1304 assertions, 0 failures, 2 skips. This looks unrelated to this PR’s Puma plugin logging change, so I’m treating it as a likely flaky/order-sensitive recurring scheduler failure and will rerun CI. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #737.
When the Puma plugin monitor detects that Puma has gone away, it logs a shutdown message before sending
INTto stop Solid Queue. If the controlling terminal has already been closed, Puma's log writer can raiseErrno::EIO, preventing the shutdown signal from being sent.This makes plugin logging tolerate
Errno::EIOso shutdown can continue.Changes
Errno::EIOfrom the Puma pluginloghelperValidation
TARGET_DB=sqlite RBENV_VERSION=3.4.4 bundle _2.5.16_ exec ruby -Itest test/unit/puma_plugin_test.rbTARGET_DB=sqlite RBENV_VERSION=3.4.4 bundle exec ruby -Itest test/integration/puma/plugin_async_test.rbTARGET_DB=sqlite RBENV_VERSION=3.4.4 bundle exec ruby -Itest test/integration/puma/plugin_fork_test.rbRBENV_VERSION=3.4.4 bundle exec rubocop lib/puma/plugin/solid_queue.rb test/unit/puma_plugin_test.rb