-
Notifications
You must be signed in to change notification settings - Fork 5
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
Switch from WEBrick to Puma #112
Conversation
1f6c099
to
1702563
Compare
1702563
to
a4b5040
Compare
5dcbee3
to
529392f
Compare
Looks good but can we update the smoke test so it runs both Rack 2 and 3 - https://github.com/gocardless/que/blob/master/.github/workflows/tests.yml#L22-L57 |
8523a09
to
bca0dd5
Compare
@stephenbinns I've just updated the smoke tests - does that look okay? My implementation feels a bit hacky but I'm not sure of a better way to ensure it uses both Rack versions |
bca0dd5
to
5fcf274
Compare
Makes sense, as for making it a bit less hacky you should be able to put a conditional in the Gemfile to achieve the same result if ENV['RACK_VERSION'] == '2.0'
gem "rack", "~> 2.0"
else
gem "rack", "~> 3.0"
end And then pass the context in the env for the github action env:
RACK_VERSION: "${{ matrix.rack-version }}" |
31ac735
to
b479947
Compare
Gemfile
Outdated
@@ -25,6 +25,13 @@ group :test do | |||
gem 'rspec', '~> 3.9' | |||
end | |||
|
|||
gem "rack", ENV['RACK_VERSION'] | |||
if ENV['RACK_VERSION'] == '2.0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Versions can be compared using: https://stackoverflow.com/a/3064161
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, updated - thanks!
b479947
to
0063b34
Compare
3717bc3
to
aa62ef9
Compare
aa62ef9
to
a2c331f
Compare
WEBrick appears to be approaching EOL and is being removed from Rackup, as mentioned here. This is causing issues with a number of services as discussed here. By switching to Puma we can solve this issue while also still supporting both Rack 2 and 3.