Skip to content

Commit fde5dbe

Browse files
ashwin47claude
andcommitted
Use fork mode as default per review feedback
Switch to official solid_queue gem and use fork mode (the default) for multi-CPU support. Async mode remains available as opt-in via SOLID_QUEUE_IN_PUMA=true for memory-constrained environments. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent f8acee8 commit fde5dbe

4 files changed

Lines changed: 39 additions & 37 deletions

File tree

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ gem "redis", "~> 5.4"
1515
gem "puma", "~> 6.6"
1616

1717
# Jobs
18-
gem "solid_queue", github: "joshleblanc/solid_queue", branch: "async-mode"
18+
gem "solid_queue"
1919

2020
# Assets
2121
gem "propshaft", github: "rails/propshaft"

Gemfile.lock

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,6 @@ GIT
66
actionpack (>= 7.1.0)
77
railties (>= 7.1.0)
88

9-
GIT
10-
remote: https://github.com/joshleblanc/solid_queue.git
11-
revision: d122b5eb5ce26ea1cf1f5741a2c40a88cc02822d
12-
branch: async-mode
13-
specs:
14-
solid_queue (1.2.4)
15-
activejob (>= 7.1)
16-
activerecord (>= 7.1)
17-
concurrent-ruby (>= 1.3.1)
18-
fugit (~> 1.11)
19-
railties (>= 7.1)
20-
thor (>= 1.3.1)
21-
229
GIT
2310
remote: https://github.com/rails/importmap-rails.git
2411
revision: 51c1a531327fc04ed4552bb0fd523eb43561b817
@@ -138,6 +125,19 @@ GIT
138125
tsort (>= 0.2)
139126
zeitwerk (~> 2.6)
140127

128+
GIT
129+
remote: https://github.com/rails/solid_queue.git
130+
revision: 463612ee6dc5b63edc7ad1d0034754b8cf68b524
131+
tag: v1.3.0
132+
specs:
133+
solid_queue (1.3.0)
134+
activejob (>= 7.1)
135+
activerecord (>= 7.1)
136+
concurrent-ruby (>= 1.3.1)
137+
fugit (~> 1.11)
138+
railties (>= 7.1)
139+
thor (>= 1.3.1)
140+
141141
GEM
142142
remote: https://rubygems.org/
143143
specs:
@@ -149,7 +149,7 @@ GEM
149149
base64 (0.3.0)
150150
bcrypt (3.1.20)
151151
benchmark (0.5.0)
152-
bigdecimal (3.3.1)
152+
bigdecimal (4.0.1)
153153
brakeman (7.1.2)
154154
racc
155155
builder (3.3.0)
@@ -163,18 +163,18 @@ GEM
163163
regexp_parser (>= 1.5, < 3.0)
164164
xpath (~> 3.2)
165165
chunky_png (1.4.0)
166-
concurrent-ruby (1.3.5)
166+
concurrent-ruby (1.3.6)
167167
connection_pool (2.5.5)
168168
crack (1.0.0)
169169
bigdecimal
170170
rexml
171171
crass (1.0.6)
172-
date (3.5.0)
172+
date (3.5.1)
173173
debug (1.11.0)
174174
irb (~> 1.10)
175175
reline (>= 0.3.8)
176176
drb (2.2.3)
177-
erb (6.0.0)
177+
erb (6.0.1)
178178
erubi (1.13.1)
179179
et-orbi (1.4.0)
180180
tzinfo
@@ -193,20 +193,20 @@ GEM
193193
globalid (1.3.0)
194194
activesupport (>= 6.1)
195195
hashdiff (1.2.0)
196-
i18n (1.14.7)
196+
i18n (1.14.8)
197197
concurrent-ruby (~> 1.0)
198198
image_processing (1.14.0)
199199
mini_magick (>= 4.9.5, < 6)
200200
ruby-vips (>= 2.0.17, < 3)
201-
io-console (0.8.1)
202-
irb (1.15.3)
201+
io-console (0.8.2)
202+
irb (1.16.0)
203203
pp (>= 0.6.0)
204204
rdoc (>= 4.0.0)
205205
reline (>= 0.4.2)
206206
jbuilder (2.14.1)
207207
actionview (>= 7.0.0)
208208
activesupport (>= 7.0.0)
209-
json (2.13.2)
209+
json (2.18.0)
210210
jwt (3.1.2)
211211
base64
212212
kredis (1.8.0)
@@ -216,7 +216,7 @@ GEM
216216
language_server-protocol (3.17.0.5)
217217
lint_roller (1.1.0)
218218
logger (1.7.0)
219-
loofah (2.24.1)
219+
loofah (2.25.0)
220220
crass (~> 1.0.2)
221221
nokogiri (>= 1.12.0)
222222
mail (2.9.0)
@@ -230,7 +230,7 @@ GEM
230230
mini_magick (5.3.1)
231231
logger
232232
mini_mime (1.1.5)
233-
minitest (5.26.2)
233+
minitest (5.27.0)
234234
mocha (2.7.1)
235235
ruby2_keywords (>= 0.0.5)
236236
net-http-persistent (4.0.6)
@@ -245,13 +245,13 @@ GEM
245245
net-smtp (0.5.1)
246246
net-protocol
247247
nio4r (2.7.5)
248-
nokogiri (1.18.10-aarch64-linux-gnu)
248+
nokogiri (1.19.0-aarch64-linux-gnu)
249249
racc (~> 1.4)
250-
nokogiri (1.18.10-arm64-darwin)
250+
nokogiri (1.19.0-arm64-darwin)
251251
racc (~> 1.4)
252-
nokogiri (1.18.10-x86_64-darwin)
252+
nokogiri (1.19.0-x86_64-darwin)
253253
racc (~> 1.4)
254-
nokogiri (1.18.10-x86_64-linux-gnu)
254+
nokogiri (1.19.0-x86_64-linux-gnu)
255255
racc (~> 1.4)
256256
openssl (3.3.0)
257257
ostruct (0.6.3)
@@ -266,7 +266,7 @@ GEM
266266
prettyprint
267267
prettyprint (0.2.0)
268268
prism (1.4.0)
269-
psych (5.2.6)
269+
psych (5.3.1)
270270
date
271271
stringio
272272
public_suffix (6.0.2)
@@ -280,7 +280,7 @@ GEM
280280
rack (>= 3.0.0)
281281
rack-test (2.2.0)
282282
rack (>= 1.3)
283-
rackup (2.2.1)
283+
rackup (2.3.1)
284284
rack (>= 3)
285285
rails-dom-testing (2.3.0)
286286
activesupport (>= 5.0.0)
@@ -295,7 +295,7 @@ GEM
295295
railties (> 3.1)
296296
rainbow (3.1.1)
297297
rake (13.3.1)
298-
rdoc (6.16.1)
298+
rdoc (7.0.3)
299299
erb
300300
psych (>= 4.0.0)
301301
tsort
@@ -364,13 +364,13 @@ GEM
364364
sqlite3 (2.7.3-x86_64-linux-gnu)
365365
stimulus-rails (1.3.4)
366366
railties (>= 6.0.0)
367-
stringio (3.1.8)
368-
thor (1.4.0)
367+
stringio (3.2.0)
368+
thor (1.5.0)
369369
thruster (0.1.15-aarch64-linux)
370370
thruster (0.1.15-arm64-darwin)
371371
thruster (0.1.15-x86_64-darwin)
372372
thruster (0.1.15-x86_64-linux)
373-
timeout (0.4.4)
373+
timeout (0.6.0)
374374
tsort (0.2.0)
375375
tzinfo (2.0.6)
376376
concurrent-ruby (~> 1.0)
@@ -393,7 +393,7 @@ GEM
393393
websocket-extensions (0.1.5)
394394
xpath (3.2.0)
395395
nokogiri (~> 1.8)
396-
zeitwerk (2.7.3)
396+
zeitwerk (2.7.4)
397397

398398
PLATFORMS
399399
aarch64-linux

Procfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1-
web: SOLID_QUEUE_IN_PUMA=true bundle exec thrust bin/start-app
1+
web: bundle exec thrust bin/start-app
2+
jobs: bundle exec bin/jobs
23
redis: redis-server config/redis.conf

config/puma.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@
4747
# Allow puma to be restarted by `bin/rails restart` command.
4848
plugin :tmp_restart
4949

50-
# Run Solid Queue inside Puma (async mode = threads instead of forking processes)
50+
# Optionally run Solid Queue inside Puma for lower memory usage.
51+
# Set SOLID_QUEUE_IN_PUMA=true and remove the jobs process from Procfile.
5152
if ENV["SOLID_QUEUE_IN_PUMA"]
5253
plugin :solid_queue
5354
solid_queue_mode :async

0 commit comments

Comments
 (0)