shoryuken 7.0.0.alpha1 → 7.0.0.rc1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/push.yml +3 -3
- data/.github/workflows/specs.yml +27 -17
- data/.github/workflows/verify-action-pins.yml +1 -1
- data/.rspec +2 -1
- data/.ruby-version +1 -1
- data/Appraisals +6 -18
- data/CHANGELOG.md +200 -142
- data/Gemfile +1 -0
- data/README.md +12 -13
- data/bin/cli/base.rb +1 -2
- data/bin/cli/sqs.rb +6 -5
- data/bin/shoryuken +3 -2
- data/gemfiles/rails_7_2.gemfile +1 -0
- data/gemfiles/rails_8_0.gemfile +1 -0
- data/gemfiles/{rails_7_1.gemfile → rails_8_1.gemfile} +2 -1
- data/lib/shoryuken/body_parser.rb +3 -1
- data/lib/shoryuken/client.rb +2 -0
- data/lib/shoryuken/default_exception_handler.rb +2 -0
- data/lib/shoryuken/default_worker_registry.rb +11 -11
- data/lib/shoryuken/environment_loader.rb +6 -6
- data/lib/shoryuken/extensions/active_job_adapter.rb +21 -6
- data/lib/shoryuken/extensions/active_job_concurrent_send_adapter.rb +5 -5
- data/lib/shoryuken/extensions/active_job_extensions.rb +2 -0
- data/lib/shoryuken/fetcher.rb +4 -2
- data/lib/shoryuken/helpers/atomic_boolean.rb +44 -0
- data/lib/shoryuken/helpers/atomic_counter.rb +104 -0
- data/lib/shoryuken/helpers/atomic_hash.rb +182 -0
- data/lib/shoryuken/helpers/hash_utils.rb +56 -0
- data/lib/shoryuken/helpers/string_utils.rb +65 -0
- data/lib/shoryuken/helpers/timer_task.rb +66 -0
- data/lib/shoryuken/inline_message.rb +22 -0
- data/lib/shoryuken/launcher.rb +16 -0
- data/lib/shoryuken/logging/base.rb +26 -0
- data/lib/shoryuken/logging/pretty.rb +25 -0
- data/lib/shoryuken/logging/without_timestamp.rb +25 -0
- data/lib/shoryuken/logging.rb +6 -12
- data/lib/shoryuken/manager.rb +6 -4
- data/lib/shoryuken/message.rb +116 -1
- data/lib/shoryuken/middleware/chain.rb +140 -43
- data/lib/shoryuken/middleware/entry.rb +30 -0
- data/lib/shoryuken/middleware/server/active_record.rb +2 -0
- data/lib/shoryuken/middleware/server/auto_delete.rb +2 -0
- data/lib/shoryuken/middleware/server/auto_extend_visibility.rb +11 -11
- data/lib/shoryuken/middleware/server/exponential_backoff_retry.rb +5 -3
- data/lib/shoryuken/middleware/server/timing.rb +2 -0
- data/lib/shoryuken/options.rb +9 -5
- data/lib/shoryuken/polling/base_strategy.rb +126 -0
- data/lib/shoryuken/polling/queue_configuration.rb +103 -0
- data/lib/shoryuken/polling/strict_priority.rb +2 -0
- data/lib/shoryuken/polling/weighted_round_robin.rb +2 -0
- data/lib/shoryuken/processor.rb +5 -2
- data/lib/shoryuken/queue.rb +6 -4
- data/lib/shoryuken/runner.rb +12 -12
- data/lib/shoryuken/util.rb +6 -6
- data/lib/shoryuken/version.rb +3 -1
- data/lib/shoryuken/worker/default_executor.rb +2 -0
- data/lib/shoryuken/worker/inline_executor.rb +3 -1
- data/lib/shoryuken/worker.rb +173 -0
- data/lib/shoryuken/worker_registry.rb +2 -0
- data/lib/shoryuken.rb +8 -28
- data/shoryuken.gemspec +6 -6
- data/spec/integration/active_job_continuation_spec.rb +145 -0
- data/spec/integration/launcher_spec.rb +2 -3
- data/spec/shared_examples_for_active_job.rb +13 -8
- data/spec/shoryuken/body_parser_spec.rb +1 -2
- data/spec/shoryuken/client_spec.rb +1 -1
- data/spec/shoryuken/default_exception_handler_spec.rb +9 -10
- data/spec/shoryuken/default_worker_registry_spec.rb +1 -2
- data/spec/shoryuken/environment_loader_spec.rb +9 -8
- data/spec/shoryuken/extensions/active_job_adapter_spec.rb +2 -1
- data/spec/shoryuken/extensions/active_job_base_spec.rb +2 -1
- data/spec/shoryuken/extensions/active_job_concurrent_send_adapter_spec.rb +2 -1
- data/spec/shoryuken/extensions/active_job_continuation_spec.rb +110 -0
- data/spec/shoryuken/extensions/active_job_wrapper_spec.rb +2 -1
- data/spec/shoryuken/fetcher_spec.rb +23 -26
- data/spec/shoryuken/helpers/atomic_boolean_spec.rb +196 -0
- data/spec/shoryuken/helpers/atomic_counter_spec.rb +177 -0
- data/spec/shoryuken/helpers/atomic_hash_spec.rb +307 -0
- data/spec/shoryuken/helpers/hash_utils_spec.rb +145 -0
- data/spec/shoryuken/helpers/string_utils_spec.rb +124 -0
- data/spec/shoryuken/helpers/timer_task_spec.rb +298 -0
- data/spec/shoryuken/helpers_integration_spec.rb +96 -0
- data/spec/shoryuken/inline_message_spec.rb +196 -0
- data/spec/shoryuken/launcher_spec.rb +23 -2
- data/spec/shoryuken/manager_spec.rb +1 -2
- data/spec/shoryuken/middleware/chain_spec.rb +1 -1
- data/spec/shoryuken/middleware/server/auto_delete_spec.rb +1 -1
- data/spec/shoryuken/middleware/server/auto_extend_visibility_spec.rb +1 -1
- data/spec/shoryuken/middleware/server/exponential_backoff_retry_spec.rb +1 -1
- data/spec/shoryuken/middleware/server/timing_spec.rb +1 -1
- data/spec/shoryuken/options_spec.rb +4 -4
- data/spec/shoryuken/polling/base_strategy_spec.rb +280 -0
- data/spec/shoryuken/polling/queue_configuration_spec.rb +195 -0
- data/spec/shoryuken/polling/strict_priority_spec.rb +1 -1
- data/spec/shoryuken/polling/weighted_round_robin_spec.rb +1 -1
- data/spec/shoryuken/processor_spec.rb +1 -1
- data/spec/shoryuken/queue_spec.rb +2 -3
- data/spec/shoryuken/runner_spec.rb +1 -3
- data/spec/shoryuken/util_spec.rb +1 -1
- data/spec/shoryuken/worker/default_executor_spec.rb +1 -1
- data/spec/shoryuken/worker/inline_executor_spec.rb +1 -1
- data/spec/shoryuken/worker_spec.rb +15 -11
- data/spec/shoryuken_spec.rb +1 -1
- data/spec/spec_helper.rb +16 -0
- metadata +72 -29
- data/.github/FUNDING.yml +0 -12
- data/gemfiles/rails_6_1.gemfile +0 -18
- data/gemfiles/rails_7_0.gemfile +0 -19
- data/lib/shoryuken/core_ext.rb +0 -69
- data/lib/shoryuken/polling/base.rb +0 -67
- data/shoryuken.jpg +0 -0
- data/spec/shoryuken/core_ext_spec.rb +0 -40
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
RSpec.describe Shoryuken::Polling::QueueConfiguration do
|
|
4
|
+
describe '#initialize' do
|
|
5
|
+
it 'creates configuration with name and options' do
|
|
6
|
+
config = described_class.new('test_queue', { priority: :high })
|
|
7
|
+
|
|
8
|
+
expect(config.name).to eq('test_queue')
|
|
9
|
+
expect(config.options).to eq({ priority: :high })
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
it 'creates configuration with empty options' do
|
|
13
|
+
config = described_class.new('simple_queue', {})
|
|
14
|
+
|
|
15
|
+
expect(config.name).to eq('simple_queue')
|
|
16
|
+
expect(config.options).to eq({})
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
it 'accepts nil options' do
|
|
20
|
+
config = described_class.new('queue', nil)
|
|
21
|
+
|
|
22
|
+
expect(config.name).to eq('queue')
|
|
23
|
+
expect(config.options).to be_nil
|
|
24
|
+
end
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
describe '#hash' do
|
|
28
|
+
it 'returns hash based on queue name' do
|
|
29
|
+
config1 = described_class.new('queue', {})
|
|
30
|
+
config2 = described_class.new('queue', { weight: 5 })
|
|
31
|
+
|
|
32
|
+
expect(config1.hash).to eq(config2.hash)
|
|
33
|
+
expect(config1.hash).to eq('queue'.hash)
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
it 'returns different hash for different queue names' do
|
|
37
|
+
config1 = described_class.new('queue1', {})
|
|
38
|
+
config2 = described_class.new('queue2', {})
|
|
39
|
+
|
|
40
|
+
expect(config1.hash).not_to eq(config2.hash)
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
describe '#==' do
|
|
45
|
+
context 'when comparing with another QueueConfiguration' do
|
|
46
|
+
it 'returns true for same name and options' do
|
|
47
|
+
config1 = described_class.new('queue', { weight: 5 })
|
|
48
|
+
config2 = described_class.new('queue', { weight: 5 })
|
|
49
|
+
|
|
50
|
+
expect(config1).to eq(config2)
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
it 'returns false for same name but different options' do
|
|
54
|
+
config1 = described_class.new('queue', { weight: 5 })
|
|
55
|
+
config2 = described_class.new('queue', { weight: 10 })
|
|
56
|
+
|
|
57
|
+
expect(config1).not_to eq(config2)
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
it 'returns false for different names' do
|
|
61
|
+
config1 = described_class.new('queue1', {})
|
|
62
|
+
config2 = described_class.new('queue2', {})
|
|
63
|
+
|
|
64
|
+
expect(config1).not_to eq(config2)
|
|
65
|
+
end
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
context 'when comparing with a string' do
|
|
69
|
+
it 'returns true when options are empty and names match' do
|
|
70
|
+
config = described_class.new('test_queue', {})
|
|
71
|
+
|
|
72
|
+
expect(config).to eq('test_queue')
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
it 'returns false when options are not empty' do
|
|
76
|
+
config = described_class.new('test_queue', { weight: 5 })
|
|
77
|
+
|
|
78
|
+
expect(config).not_to eq('test_queue')
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
it 'returns false when names do not match' do
|
|
82
|
+
config = described_class.new('queue1', {})
|
|
83
|
+
|
|
84
|
+
expect(config).not_to eq('queue2')
|
|
85
|
+
end
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
context 'when comparing with other objects' do
|
|
89
|
+
it 'returns false for non-string, non-QueueConfiguration objects' do
|
|
90
|
+
config = described_class.new('queue', {})
|
|
91
|
+
|
|
92
|
+
expect(config).not_to eq(123)
|
|
93
|
+
expect(config).not_to eq([])
|
|
94
|
+
expect(config).not_to eq({ name: 'queue' })
|
|
95
|
+
end
|
|
96
|
+
end
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
describe '#eql?' do
|
|
100
|
+
it 'behaves the same as ==' do
|
|
101
|
+
config1 = described_class.new('queue', {})
|
|
102
|
+
config2 = described_class.new('queue', {})
|
|
103
|
+
|
|
104
|
+
expect(config1.eql?(config2)).to eq(config1 == config2)
|
|
105
|
+
expect(config1.eql?('queue')).to eq(config1 == 'queue')
|
|
106
|
+
end
|
|
107
|
+
end
|
|
108
|
+
|
|
109
|
+
describe '#to_s' do
|
|
110
|
+
context 'when options are empty' do
|
|
111
|
+
it 'returns just the queue name' do
|
|
112
|
+
config = described_class.new('simple_queue', {})
|
|
113
|
+
|
|
114
|
+
expect(config.to_s).to eq('simple_queue')
|
|
115
|
+
end
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
context 'when options are present' do
|
|
119
|
+
it 'returns detailed representation with options' do
|
|
120
|
+
config = described_class.new('complex_queue', { priority: :high, weight: 5 })
|
|
121
|
+
|
|
122
|
+
expect(config.to_s).to include('#<QueueConfiguration complex_queue options={')
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
it 'handles single option' do
|
|
126
|
+
config = described_class.new('weighted_queue', { weight: 10 })
|
|
127
|
+
|
|
128
|
+
expect(config.to_s).to include('#<QueueConfiguration weighted_queue options={')
|
|
129
|
+
end
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
context 'when options are nil' do
|
|
133
|
+
it 'returns detailed representation' do
|
|
134
|
+
config = described_class.new('nil_options_queue', nil)
|
|
135
|
+
|
|
136
|
+
expect(config.to_s).to eq('#<QueueConfiguration nil_options_queue options=nil>')
|
|
137
|
+
end
|
|
138
|
+
end
|
|
139
|
+
end
|
|
140
|
+
|
|
141
|
+
describe 'struct behavior' do
|
|
142
|
+
it 'provides attribute accessors' do
|
|
143
|
+
config = described_class.new('queue', { weight: 5 })
|
|
144
|
+
|
|
145
|
+
expect(config.name).to eq('queue')
|
|
146
|
+
expect(config.options).to eq({ weight: 5 })
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
it 'allows attribute modification' do
|
|
150
|
+
config = described_class.new('queue', {})
|
|
151
|
+
|
|
152
|
+
config.name = 'new_queue'
|
|
153
|
+
config.options = { priority: :low }
|
|
154
|
+
|
|
155
|
+
expect(config.name).to eq('new_queue')
|
|
156
|
+
expect(config.options).to eq({ priority: :low })
|
|
157
|
+
end
|
|
158
|
+
|
|
159
|
+
it 'supports array-like access' do
|
|
160
|
+
config = described_class.new('queue', { weight: 5 })
|
|
161
|
+
|
|
162
|
+
expect(config[0]).to eq('queue')
|
|
163
|
+
expect(config[1]).to eq({ weight: 5 })
|
|
164
|
+
end
|
|
165
|
+
end
|
|
166
|
+
|
|
167
|
+
describe 'usage as hash key' do
|
|
168
|
+
it 'can be used as hash keys' do
|
|
169
|
+
config1 = described_class.new('queue', {})
|
|
170
|
+
config2 = described_class.new('queue', {}) # Same config
|
|
171
|
+
|
|
172
|
+
hash = {}
|
|
173
|
+
hash[config1] = 'value1'
|
|
174
|
+
hash[config2] = 'value2'
|
|
175
|
+
|
|
176
|
+
# Same queue name and options should use same hash key
|
|
177
|
+
expect(hash[config1]).to eq('value2')
|
|
178
|
+
expect(hash[config2]).to eq('value2')
|
|
179
|
+
expect(hash.size).to eq(1)
|
|
180
|
+
end
|
|
181
|
+
|
|
182
|
+
it 'different queue names create different keys' do
|
|
183
|
+
config1 = described_class.new('queue1', {})
|
|
184
|
+
config2 = described_class.new('queue2', {})
|
|
185
|
+
|
|
186
|
+
hash = {}
|
|
187
|
+
hash[config1] = 'value1'
|
|
188
|
+
hash[config2] = 'value2'
|
|
189
|
+
|
|
190
|
+
expect(hash[config1]).to eq('value1')
|
|
191
|
+
expect(hash[config2]).to eq('value2')
|
|
192
|
+
expect(hash.size).to eq(2)
|
|
193
|
+
end
|
|
194
|
+
end
|
|
195
|
+
end
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# rubocop:disable Metrics/BlockLength
|
|
4
3
|
RSpec.describe Shoryuken::Queue do
|
|
5
4
|
let(:credentials) { Aws::Credentials.new('access_key_id', 'secret_access_key') }
|
|
6
5
|
let(:sqs) { Aws::SQS::Client.new(stub_responses: true, credentials: credentials) }
|
|
@@ -30,7 +29,7 @@ RSpec.describe Shoryuken::Queue do
|
|
|
30
29
|
let(:queue_url) { "http://localhost:4576/queue/#{queue_name}" }
|
|
31
30
|
|
|
32
31
|
it 'instantiates by URL and validate the URL' do
|
|
33
|
-
# See https://github.com/
|
|
32
|
+
# See https://github.com/ruby-shoryuken/shoryuken/pull/551
|
|
34
33
|
expect_any_instance_of(described_class).to receive(:fifo?).and_return(false)
|
|
35
34
|
|
|
36
35
|
subject = described_class.new(sqs, queue_url)
|
data/spec/shoryuken/util_spec.rb
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
RSpec.describe Shoryuken::Worker do
|
|
4
4
|
let(:sqs_queue) { double 'SQS Queue' }
|
|
@@ -108,14 +108,16 @@ RSpec.describe Shoryuken::Worker do
|
|
|
108
108
|
end
|
|
109
109
|
|
|
110
110
|
describe '.server_middleware' do
|
|
111
|
-
|
|
112
|
-
|
|
111
|
+
let(:fake_middleware_class) do
|
|
112
|
+
Class.new do
|
|
113
113
|
def call(*_args)
|
|
114
114
|
yield
|
|
115
115
|
end
|
|
116
116
|
end
|
|
117
117
|
end
|
|
118
118
|
|
|
119
|
+
before { fake_middleware_class }
|
|
120
|
+
|
|
119
121
|
context 'no middleware is defined in the worker' do
|
|
120
122
|
it 'returns the list of global middlewares' do
|
|
121
123
|
expect(TestWorker.server_middleware).to satisfy do |chain|
|
|
@@ -147,27 +149,29 @@ RSpec.describe Shoryuken::Worker do
|
|
|
147
149
|
end
|
|
148
150
|
|
|
149
151
|
context 'the worker modifies the chain' do
|
|
150
|
-
|
|
151
|
-
|
|
152
|
+
let(:new_test_worker3_class) do
|
|
153
|
+
ref = fake_middleware_class
|
|
154
|
+
|
|
155
|
+
Class.new do
|
|
152
156
|
include Shoryuken::Worker
|
|
153
157
|
|
|
154
158
|
server_middleware do |chain|
|
|
155
159
|
chain.remove Shoryuken::Middleware::Server::Timing
|
|
156
|
-
chain.insert_before Shoryuken::Middleware::Server::AutoDelete,
|
|
160
|
+
chain.insert_before Shoryuken::Middleware::Server::AutoDelete, ref
|
|
157
161
|
end
|
|
158
162
|
end
|
|
159
163
|
end
|
|
160
164
|
|
|
161
165
|
it 'returns the combined global and worker middlewares' do
|
|
162
|
-
expect(
|
|
166
|
+
expect(new_test_worker3_class.server_middleware).not_to satisfy do |chain|
|
|
163
167
|
chain.exists?(Shoryuken::Middleware::Server::Timing)
|
|
164
168
|
end
|
|
165
169
|
|
|
166
|
-
expect(
|
|
167
|
-
chain.exists?(
|
|
170
|
+
expect(new_test_worker3_class.server_middleware).to satisfy do |chain|
|
|
171
|
+
chain.exists?(fake_middleware_class)
|
|
168
172
|
end
|
|
169
173
|
|
|
170
|
-
expect(
|
|
174
|
+
expect(new_test_worker3_class.server_middleware).to satisfy do |chain|
|
|
171
175
|
chain.exists?(Shoryuken::Middleware::Server::AutoDelete)
|
|
172
176
|
end
|
|
173
177
|
end
|
|
@@ -182,7 +186,7 @@ RSpec.describe Shoryuken::Worker do
|
|
|
182
186
|
end
|
|
183
187
|
|
|
184
188
|
expect(Shoryuken.server_middleware).not_to satisfy do |chain|
|
|
185
|
-
chain.exists?(
|
|
189
|
+
chain.exists?(fake_middleware_class)
|
|
186
190
|
end
|
|
187
191
|
end
|
|
188
192
|
end
|
data/spec/shoryuken_spec.rb
CHANGED
data/spec/spec_helper.rb
CHANGED
|
@@ -1,3 +1,19 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
Warning[:performance] = true if RUBY_VERSION >= '3.3'
|
|
4
|
+
Warning[:deprecated] = true
|
|
5
|
+
$VERBOSE = true
|
|
6
|
+
|
|
7
|
+
require 'warning'
|
|
8
|
+
|
|
9
|
+
Warning.process do |warning|
|
|
10
|
+
next unless warning.include?(Dir.pwd)
|
|
11
|
+
next if warning.include?('useless use of a variable in void context') && warning.include?('core_ext')
|
|
12
|
+
next if warning.include?('vendor/')
|
|
13
|
+
|
|
14
|
+
raise "Warning in your code: #{warning}"
|
|
15
|
+
end
|
|
16
|
+
|
|
1
17
|
require 'bundler/setup'
|
|
2
18
|
Bundler.setup
|
|
3
19
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: shoryuken
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 7.0.0.
|
|
4
|
+
version: 7.0.0.rc1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Pablo Cantero
|
|
@@ -10,27 +10,27 @@ cert_chain: []
|
|
|
10
10
|
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
11
|
dependencies:
|
|
12
12
|
- !ruby/object:Gem::Dependency
|
|
13
|
-
name:
|
|
13
|
+
name: aws-sdk-sqs
|
|
14
14
|
requirement: !ruby/object:Gem::Requirement
|
|
15
15
|
requirements:
|
|
16
16
|
- - ">="
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
|
-
version:
|
|
19
|
-
type: :
|
|
18
|
+
version: 1.66.0
|
|
19
|
+
type: :runtime
|
|
20
20
|
prerelease: false
|
|
21
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
22
22
|
requirements:
|
|
23
23
|
- - ">="
|
|
24
24
|
- !ruby/object:Gem::Version
|
|
25
|
-
version:
|
|
25
|
+
version: 1.66.0
|
|
26
26
|
- !ruby/object:Gem::Dependency
|
|
27
|
-
name:
|
|
27
|
+
name: concurrent-ruby
|
|
28
28
|
requirement: !ruby/object:Gem::Requirement
|
|
29
29
|
requirements:
|
|
30
30
|
- - ">="
|
|
31
31
|
- !ruby/object:Gem::Version
|
|
32
32
|
version: '0'
|
|
33
|
-
type: :
|
|
33
|
+
type: :runtime
|
|
34
34
|
prerelease: false
|
|
35
35
|
version_requirements: !ruby/object:Gem::Requirement
|
|
36
36
|
requirements:
|
|
@@ -38,13 +38,13 @@ dependencies:
|
|
|
38
38
|
- !ruby/object:Gem::Version
|
|
39
39
|
version: '0'
|
|
40
40
|
- !ruby/object:Gem::Dependency
|
|
41
|
-
name:
|
|
41
|
+
name: thor
|
|
42
42
|
requirement: !ruby/object:Gem::Requirement
|
|
43
43
|
requirements:
|
|
44
44
|
- - ">="
|
|
45
45
|
- !ruby/object:Gem::Version
|
|
46
46
|
version: '0'
|
|
47
|
-
type: :
|
|
47
|
+
type: :runtime
|
|
48
48
|
prerelease: false
|
|
49
49
|
version_requirements: !ruby/object:Gem::Requirement
|
|
50
50
|
requirements:
|
|
@@ -52,7 +52,21 @@ dependencies:
|
|
|
52
52
|
- !ruby/object:Gem::Version
|
|
53
53
|
version: '0'
|
|
54
54
|
- !ruby/object:Gem::Dependency
|
|
55
|
-
name:
|
|
55
|
+
name: zeitwerk
|
|
56
|
+
requirement: !ruby/object:Gem::Requirement
|
|
57
|
+
requirements:
|
|
58
|
+
- - "~>"
|
|
59
|
+
- !ruby/object:Gem::Version
|
|
60
|
+
version: '2.6'
|
|
61
|
+
type: :runtime
|
|
62
|
+
prerelease: false
|
|
63
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
64
|
+
requirements:
|
|
65
|
+
- - "~>"
|
|
66
|
+
- !ruby/object:Gem::Version
|
|
67
|
+
version: '2.6'
|
|
68
|
+
- !ruby/object:Gem::Dependency
|
|
69
|
+
name: dotenv
|
|
56
70
|
requirement: !ruby/object:Gem::Requirement
|
|
57
71
|
requirements:
|
|
58
72
|
- - ">="
|
|
@@ -66,27 +80,27 @@ dependencies:
|
|
|
66
80
|
- !ruby/object:Gem::Version
|
|
67
81
|
version: '0'
|
|
68
82
|
- !ruby/object:Gem::Dependency
|
|
69
|
-
name:
|
|
83
|
+
name: ostruct
|
|
70
84
|
requirement: !ruby/object:Gem::Requirement
|
|
71
85
|
requirements:
|
|
72
86
|
- - ">="
|
|
73
87
|
- !ruby/object:Gem::Version
|
|
74
|
-
version:
|
|
75
|
-
type: :
|
|
88
|
+
version: '0'
|
|
89
|
+
type: :development
|
|
76
90
|
prerelease: false
|
|
77
91
|
version_requirements: !ruby/object:Gem::Requirement
|
|
78
92
|
requirements:
|
|
79
93
|
- - ">="
|
|
80
94
|
- !ruby/object:Gem::Version
|
|
81
|
-
version:
|
|
95
|
+
version: '0'
|
|
82
96
|
- !ruby/object:Gem::Dependency
|
|
83
|
-
name:
|
|
97
|
+
name: rake
|
|
84
98
|
requirement: !ruby/object:Gem::Requirement
|
|
85
99
|
requirements:
|
|
86
100
|
- - ">="
|
|
87
101
|
- !ruby/object:Gem::Version
|
|
88
102
|
version: '0'
|
|
89
|
-
type: :
|
|
103
|
+
type: :development
|
|
90
104
|
prerelease: false
|
|
91
105
|
version_requirements: !ruby/object:Gem::Requirement
|
|
92
106
|
requirements:
|
|
@@ -94,13 +108,13 @@ dependencies:
|
|
|
94
108
|
- !ruby/object:Gem::Version
|
|
95
109
|
version: '0'
|
|
96
110
|
- !ruby/object:Gem::Dependency
|
|
97
|
-
name:
|
|
111
|
+
name: rspec
|
|
98
112
|
requirement: !ruby/object:Gem::Requirement
|
|
99
113
|
requirements:
|
|
100
114
|
- - ">="
|
|
101
115
|
- !ruby/object:Gem::Version
|
|
102
116
|
version: '0'
|
|
103
|
-
type: :
|
|
117
|
+
type: :development
|
|
104
118
|
prerelease: false
|
|
105
119
|
version_requirements: !ruby/object:Gem::Requirement
|
|
106
120
|
requirements:
|
|
@@ -118,7 +132,6 @@ files:
|
|
|
118
132
|
- ".devcontainer/Dockerfile"
|
|
119
133
|
- ".devcontainer/base.Dockerfile"
|
|
120
134
|
- ".devcontainer/devcontainer.json"
|
|
121
|
-
- ".github/FUNDING.yml"
|
|
122
135
|
- ".github/workflows/push.yml"
|
|
123
136
|
- ".github/workflows/specs.yml"
|
|
124
137
|
- ".github/workflows/verify-action-pins.yml"
|
|
@@ -139,15 +152,12 @@ files:
|
|
|
139
152
|
- examples/bootstrap_queues.rb
|
|
140
153
|
- examples/default_worker.rb
|
|
141
154
|
- gemfiles/.gitignore
|
|
142
|
-
- gemfiles/rails_6_1.gemfile
|
|
143
|
-
- gemfiles/rails_7_0.gemfile
|
|
144
|
-
- gemfiles/rails_7_1.gemfile
|
|
145
155
|
- gemfiles/rails_7_2.gemfile
|
|
146
156
|
- gemfiles/rails_8_0.gemfile
|
|
157
|
+
- gemfiles/rails_8_1.gemfile
|
|
147
158
|
- lib/shoryuken.rb
|
|
148
159
|
- lib/shoryuken/body_parser.rb
|
|
149
160
|
- lib/shoryuken/client.rb
|
|
150
|
-
- lib/shoryuken/core_ext.rb
|
|
151
161
|
- lib/shoryuken/default_exception_handler.rb
|
|
152
162
|
- lib/shoryuken/default_worker_registry.rb
|
|
153
163
|
- lib/shoryuken/environment_loader.rb
|
|
@@ -155,18 +165,30 @@ files:
|
|
|
155
165
|
- lib/shoryuken/extensions/active_job_concurrent_send_adapter.rb
|
|
156
166
|
- lib/shoryuken/extensions/active_job_extensions.rb
|
|
157
167
|
- lib/shoryuken/fetcher.rb
|
|
168
|
+
- lib/shoryuken/helpers/atomic_boolean.rb
|
|
169
|
+
- lib/shoryuken/helpers/atomic_counter.rb
|
|
170
|
+
- lib/shoryuken/helpers/atomic_hash.rb
|
|
171
|
+
- lib/shoryuken/helpers/hash_utils.rb
|
|
172
|
+
- lib/shoryuken/helpers/string_utils.rb
|
|
173
|
+
- lib/shoryuken/helpers/timer_task.rb
|
|
174
|
+
- lib/shoryuken/inline_message.rb
|
|
158
175
|
- lib/shoryuken/launcher.rb
|
|
159
176
|
- lib/shoryuken/logging.rb
|
|
177
|
+
- lib/shoryuken/logging/base.rb
|
|
178
|
+
- lib/shoryuken/logging/pretty.rb
|
|
179
|
+
- lib/shoryuken/logging/without_timestamp.rb
|
|
160
180
|
- lib/shoryuken/manager.rb
|
|
161
181
|
- lib/shoryuken/message.rb
|
|
162
182
|
- lib/shoryuken/middleware/chain.rb
|
|
183
|
+
- lib/shoryuken/middleware/entry.rb
|
|
163
184
|
- lib/shoryuken/middleware/server/active_record.rb
|
|
164
185
|
- lib/shoryuken/middleware/server/auto_delete.rb
|
|
165
186
|
- lib/shoryuken/middleware/server/auto_extend_visibility.rb
|
|
166
187
|
- lib/shoryuken/middleware/server/exponential_backoff_retry.rb
|
|
167
188
|
- lib/shoryuken/middleware/server/timing.rb
|
|
168
189
|
- lib/shoryuken/options.rb
|
|
169
|
-
- lib/shoryuken/polling/
|
|
190
|
+
- lib/shoryuken/polling/base_strategy.rb
|
|
191
|
+
- lib/shoryuken/polling/queue_configuration.rb
|
|
170
192
|
- lib/shoryuken/polling/strict_priority.rb
|
|
171
193
|
- lib/shoryuken/polling/weighted_round_robin.rb
|
|
172
194
|
- lib/shoryuken/processor.rb
|
|
@@ -180,21 +202,29 @@ files:
|
|
|
180
202
|
- lib/shoryuken/worker_registry.rb
|
|
181
203
|
- renovate.json
|
|
182
204
|
- shoryuken.gemspec
|
|
183
|
-
-
|
|
205
|
+
- spec/integration/active_job_continuation_spec.rb
|
|
184
206
|
- spec/integration/launcher_spec.rb
|
|
185
207
|
- spec/shared_examples_for_active_job.rb
|
|
186
208
|
- spec/shoryuken.yml
|
|
187
209
|
- spec/shoryuken/body_parser_spec.rb
|
|
188
210
|
- spec/shoryuken/client_spec.rb
|
|
189
|
-
- spec/shoryuken/core_ext_spec.rb
|
|
190
211
|
- spec/shoryuken/default_exception_handler_spec.rb
|
|
191
212
|
- spec/shoryuken/default_worker_registry_spec.rb
|
|
192
213
|
- spec/shoryuken/environment_loader_spec.rb
|
|
193
214
|
- spec/shoryuken/extensions/active_job_adapter_spec.rb
|
|
194
215
|
- spec/shoryuken/extensions/active_job_base_spec.rb
|
|
195
216
|
- spec/shoryuken/extensions/active_job_concurrent_send_adapter_spec.rb
|
|
217
|
+
- spec/shoryuken/extensions/active_job_continuation_spec.rb
|
|
196
218
|
- spec/shoryuken/extensions/active_job_wrapper_spec.rb
|
|
197
219
|
- spec/shoryuken/fetcher_spec.rb
|
|
220
|
+
- spec/shoryuken/helpers/atomic_boolean_spec.rb
|
|
221
|
+
- spec/shoryuken/helpers/atomic_counter_spec.rb
|
|
222
|
+
- spec/shoryuken/helpers/atomic_hash_spec.rb
|
|
223
|
+
- spec/shoryuken/helpers/hash_utils_spec.rb
|
|
224
|
+
- spec/shoryuken/helpers/string_utils_spec.rb
|
|
225
|
+
- spec/shoryuken/helpers/timer_task_spec.rb
|
|
226
|
+
- spec/shoryuken/helpers_integration_spec.rb
|
|
227
|
+
- spec/shoryuken/inline_message_spec.rb
|
|
198
228
|
- spec/shoryuken/launcher_spec.rb
|
|
199
229
|
- spec/shoryuken/manager_spec.rb
|
|
200
230
|
- spec/shoryuken/middleware/chain_spec.rb
|
|
@@ -203,6 +233,8 @@ files:
|
|
|
203
233
|
- spec/shoryuken/middleware/server/exponential_backoff_retry_spec.rb
|
|
204
234
|
- spec/shoryuken/middleware/server/timing_spec.rb
|
|
205
235
|
- spec/shoryuken/options_spec.rb
|
|
236
|
+
- spec/shoryuken/polling/base_strategy_spec.rb
|
|
237
|
+
- spec/shoryuken/polling/queue_configuration_spec.rb
|
|
206
238
|
- spec/shoryuken/polling/strict_priority_spec.rb
|
|
207
239
|
- spec/shoryuken/polling/weighted_round_robin_spec.rb
|
|
208
240
|
- spec/shoryuken/processor_spec.rb
|
|
@@ -227,31 +259,40 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
227
259
|
requirements:
|
|
228
260
|
- - ">="
|
|
229
261
|
- !ruby/object:Gem::Version
|
|
230
|
-
version: 3.
|
|
262
|
+
version: 3.1.0
|
|
231
263
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
232
264
|
requirements:
|
|
233
265
|
- - ">="
|
|
234
266
|
- !ruby/object:Gem::Version
|
|
235
267
|
version: '0'
|
|
236
268
|
requirements: []
|
|
237
|
-
rubygems_version: 3.6.
|
|
269
|
+
rubygems_version: 3.6.9
|
|
238
270
|
specification_version: 4
|
|
239
271
|
summary: Shoryuken is a super efficient AWS SQS thread based message processor
|
|
240
272
|
test_files:
|
|
273
|
+
- spec/integration/active_job_continuation_spec.rb
|
|
241
274
|
- spec/integration/launcher_spec.rb
|
|
242
275
|
- spec/shared_examples_for_active_job.rb
|
|
243
276
|
- spec/shoryuken.yml
|
|
244
277
|
- spec/shoryuken/body_parser_spec.rb
|
|
245
278
|
- spec/shoryuken/client_spec.rb
|
|
246
|
-
- spec/shoryuken/core_ext_spec.rb
|
|
247
279
|
- spec/shoryuken/default_exception_handler_spec.rb
|
|
248
280
|
- spec/shoryuken/default_worker_registry_spec.rb
|
|
249
281
|
- spec/shoryuken/environment_loader_spec.rb
|
|
250
282
|
- spec/shoryuken/extensions/active_job_adapter_spec.rb
|
|
251
283
|
- spec/shoryuken/extensions/active_job_base_spec.rb
|
|
252
284
|
- spec/shoryuken/extensions/active_job_concurrent_send_adapter_spec.rb
|
|
285
|
+
- spec/shoryuken/extensions/active_job_continuation_spec.rb
|
|
253
286
|
- spec/shoryuken/extensions/active_job_wrapper_spec.rb
|
|
254
287
|
- spec/shoryuken/fetcher_spec.rb
|
|
288
|
+
- spec/shoryuken/helpers/atomic_boolean_spec.rb
|
|
289
|
+
- spec/shoryuken/helpers/atomic_counter_spec.rb
|
|
290
|
+
- spec/shoryuken/helpers/atomic_hash_spec.rb
|
|
291
|
+
- spec/shoryuken/helpers/hash_utils_spec.rb
|
|
292
|
+
- spec/shoryuken/helpers/string_utils_spec.rb
|
|
293
|
+
- spec/shoryuken/helpers/timer_task_spec.rb
|
|
294
|
+
- spec/shoryuken/helpers_integration_spec.rb
|
|
295
|
+
- spec/shoryuken/inline_message_spec.rb
|
|
255
296
|
- spec/shoryuken/launcher_spec.rb
|
|
256
297
|
- spec/shoryuken/manager_spec.rb
|
|
257
298
|
- spec/shoryuken/middleware/chain_spec.rb
|
|
@@ -260,6 +301,8 @@ test_files:
|
|
|
260
301
|
- spec/shoryuken/middleware/server/exponential_backoff_retry_spec.rb
|
|
261
302
|
- spec/shoryuken/middleware/server/timing_spec.rb
|
|
262
303
|
- spec/shoryuken/options_spec.rb
|
|
304
|
+
- spec/shoryuken/polling/base_strategy_spec.rb
|
|
305
|
+
- spec/shoryuken/polling/queue_configuration_spec.rb
|
|
263
306
|
- spec/shoryuken/polling/strict_priority_spec.rb
|
|
264
307
|
- spec/shoryuken/polling/weighted_round_robin_spec.rb
|
|
265
308
|
- spec/shoryuken/processor_spec.rb
|
data/.github/FUNDING.yml
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
# These are supported funding model platforms
|
|
2
|
-
|
|
3
|
-
github: phstc
|
|
4
|
-
patreon: # Replace with a single Patreon username
|
|
5
|
-
open_collective: # Replace with a single Open Collective username
|
|
6
|
-
ko_fi: # Replace with a single Ko-fi username
|
|
7
|
-
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
|
|
8
|
-
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
|
|
9
|
-
liberapay: # Replace with a single Liberapay username
|
|
10
|
-
issuehunt: # Replace with a single IssueHunt username
|
|
11
|
-
otechie: # Replace with a single Otechie username
|
|
12
|
-
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
|
data/gemfiles/rails_6_1.gemfile
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
# This file was generated by Appraisal
|
|
2
|
-
|
|
3
|
-
source "https://rubygems.org"
|
|
4
|
-
|
|
5
|
-
group :test do
|
|
6
|
-
gem "activejob", "~> 6.1"
|
|
7
|
-
gem "httparty"
|
|
8
|
-
gem "multi_xml"
|
|
9
|
-
gem "simplecov"
|
|
10
|
-
end
|
|
11
|
-
|
|
12
|
-
group :development do
|
|
13
|
-
gem "appraisal", git: "https://github.com/thoughtbot/appraisal.git"
|
|
14
|
-
gem "pry-byebug", "3.9.0"
|
|
15
|
-
gem "rubocop"
|
|
16
|
-
end
|
|
17
|
-
|
|
18
|
-
gemspec path: "../"
|