Skip to content

Commit 5aa9663

Browse files
committed
Added delayed puma shutdown gem and updated puma to use plugin
1 parent 179550b commit 5aa9663

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

Gemfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ gem 'omniauth-cas', '3.0.0'
1919
gem 'omniauth-rails_csrf_protection', '~> 1.0'
2020
gem 'pg', '~> 1.4.6'
2121
gem 'puma', '~> 6.4.1'
22+
gem 'puma-plugin-delayed_stop', '~> 0.1.2'
2223
gem 'rack-timeout', '~> 0.6.3'
2324
gem 'rails', '~> 7.1.5'
2425
gem 'rsolr', '>= 1.0', '< 3'

Gemfile.lock

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -319,6 +319,8 @@ GEM
319319
public_suffix (6.0.1)
320320
puma (6.4.3)
321321
nio4r (~> 2.0)
322+
puma-plugin-delayed_stop (0.1.2)
323+
puma (>= 5.0, < 8)
322324
racc (1.8.1)
323325
rack (2.2.10)
324326
rack-protection (3.2.0)
@@ -552,6 +554,7 @@ DEPENDENCIES
552554
omniauth-rails_csrf_protection (~> 1.0)
553555
pg (~> 1.4.6)
554556
puma (~> 6.4.1)
557+
puma-plugin-delayed_stop (~> 0.1.2)
555558
rack-timeout (~> 0.6.3)
556559
rails (~> 7.1.5)
557560
rsolr (>= 1.0, < 3)

config/puma.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,7 @@
3636

3737
# Allow puma to be restarted by `bin/rails restart` command.
3838
plugin :tmp_restart
39+
40+
# Adds a drain period during shutdown so swarm can elegantly remove it from
41+
# the routing mesh
42+
plugin :delayed_stop

0 commit comments

Comments
 (0)