super_spreader 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.circleci/config.yml +145 -0
- data/.github/CODEOWNERS +3 -0
- data/.gitignore +15 -0
- data/.rspec +3 -0
- data/.ruby-version +1 -0
- data/.travis.yml +7 -0
- data/CHANGELOG.md +11 -0
- data/CONTRIBUTING.md +30 -0
- data/Gemfile +6 -0
- data/Gemfile.lock +207 -0
- data/Guardfile +18 -0
- data/LICENSE.txt +13 -0
- data/README.md +240 -0
- data/Rakefile +35 -0
- data/bin/console +14 -0
- data/bin/setup +7 -0
- data/lib/super_spreader/batch_helper.rb +40 -0
- data/lib/super_spreader/peak_schedule.rb +22 -0
- data/lib/super_spreader/redis_model.rb +51 -0
- data/lib/super_spreader/scheduler_config.rb +79 -0
- data/lib/super_spreader/scheduler_job.rb +43 -0
- data/lib/super_spreader/spread_tracker.rb +39 -0
- data/lib/super_spreader/spreader.rb +61 -0
- data/lib/super_spreader/stop_signal.rb +29 -0
- data/lib/super_spreader/version.rb +5 -0
- data/lib/super_spreader.rb +20 -0
- data/super_spreader.gemspec +46 -0
- metadata +304 -6
@@ -0,0 +1,20 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "super_spreader/version"
|
4
|
+
|
5
|
+
require "super_spreader/batch_helper"
|
6
|
+
require "super_spreader/peak_schedule"
|
7
|
+
require "super_spreader/redis_model"
|
8
|
+
require "super_spreader/scheduler_config"
|
9
|
+
require "super_spreader/scheduler_job"
|
10
|
+
require "super_spreader/spread_tracker"
|
11
|
+
require "super_spreader/spreader"
|
12
|
+
require "super_spreader/stop_signal"
|
13
|
+
|
14
|
+
module SuperSpreader
|
15
|
+
class Error < StandardError; end
|
16
|
+
|
17
|
+
class << self
|
18
|
+
attr_accessor :logger, :redis
|
19
|
+
end
|
20
|
+
end
|
@@ -0,0 +1,46 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
lib = File.expand_path("../lib", __FILE__)
|
4
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
|
+
require "super_spreader/version"
|
6
|
+
|
7
|
+
Gem::Specification.new do |spec|
|
8
|
+
spec.name = "super_spreader"
|
9
|
+
spec.version = SuperSpreader::VERSION
|
10
|
+
spec.authors = ["Benjamin Oakes"]
|
11
|
+
spec.email = ["boakes@doximity.com"]
|
12
|
+
|
13
|
+
spec.summary = "ActiveJob-based backfill orchestration library"
|
14
|
+
spec.description = "Provides tools for managing resource-efficient backfills of large datasets via ActiveJob"
|
15
|
+
spec.homepage = "https://github.com/doximity/super_spreader"
|
16
|
+
|
17
|
+
spec.metadata["homepage_uri"] = spec.homepage
|
18
|
+
spec.metadata["source_code_uri"] = spec.homepage
|
19
|
+
spec.metadata["changelog_uri"] = "https://github.com/doximity/super_spreader/blob/main/CHANGELOG.md"
|
20
|
+
|
21
|
+
# Specify which files should be added to the gem when it is released.
|
22
|
+
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
23
|
+
spec.files = Dir.chdir(File.expand_path("..", __FILE__)) do
|
24
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
25
|
+
end
|
26
|
+
spec.executables = []
|
27
|
+
spec.require_paths = ["lib"]
|
28
|
+
|
29
|
+
spec.add_dependency "activejob", ">= 6.1", "< 8.0"
|
30
|
+
spec.add_dependency "activemodel", ">= 6.1", "< 8.0"
|
31
|
+
spec.add_dependency "activerecord", ">= 6.1", "< 8.0"
|
32
|
+
spec.add_dependency "activesupport", ">= 6.1", "< 8.0"
|
33
|
+
spec.add_dependency "redis", ">= 4.8", "< 6.0"
|
34
|
+
spec.add_development_dependency "bundler"
|
35
|
+
spec.add_development_dependency "factory_bot"
|
36
|
+
spec.add_development_dependency "guard"
|
37
|
+
spec.add_development_dependency "guard-rspec"
|
38
|
+
spec.add_development_dependency "pry"
|
39
|
+
spec.add_development_dependency "rake"
|
40
|
+
spec.add_development_dependency "rspec"
|
41
|
+
spec.add_development_dependency "rspec-rails"
|
42
|
+
spec.add_development_dependency "rspec_junit_formatter"
|
43
|
+
spec.add_development_dependency "sqlite3"
|
44
|
+
spec.add_development_dependency "standard"
|
45
|
+
spec.add_development_dependency "yard"
|
46
|
+
end
|
metadata
CHANGED
@@ -1,15 +1,283 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: super_spreader
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Benjamin Oakes
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
12
|
-
dependencies:
|
11
|
+
date: 2023-11-07 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: activejob
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '6.1'
|
20
|
+
- - "<"
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: '8.0'
|
23
|
+
type: :runtime
|
24
|
+
prerelease: false
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
|
+
requirements:
|
27
|
+
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '6.1'
|
30
|
+
- - "<"
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '8.0'
|
33
|
+
- !ruby/object:Gem::Dependency
|
34
|
+
name: activemodel
|
35
|
+
requirement: !ruby/object:Gem::Requirement
|
36
|
+
requirements:
|
37
|
+
- - ">="
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: '6.1'
|
40
|
+
- - "<"
|
41
|
+
- !ruby/object:Gem::Version
|
42
|
+
version: '8.0'
|
43
|
+
type: :runtime
|
44
|
+
prerelease: false
|
45
|
+
version_requirements: !ruby/object:Gem::Requirement
|
46
|
+
requirements:
|
47
|
+
- - ">="
|
48
|
+
- !ruby/object:Gem::Version
|
49
|
+
version: '6.1'
|
50
|
+
- - "<"
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: '8.0'
|
53
|
+
- !ruby/object:Gem::Dependency
|
54
|
+
name: activerecord
|
55
|
+
requirement: !ruby/object:Gem::Requirement
|
56
|
+
requirements:
|
57
|
+
- - ">="
|
58
|
+
- !ruby/object:Gem::Version
|
59
|
+
version: '6.1'
|
60
|
+
- - "<"
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: '8.0'
|
63
|
+
type: :runtime
|
64
|
+
prerelease: false
|
65
|
+
version_requirements: !ruby/object:Gem::Requirement
|
66
|
+
requirements:
|
67
|
+
- - ">="
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '6.1'
|
70
|
+
- - "<"
|
71
|
+
- !ruby/object:Gem::Version
|
72
|
+
version: '8.0'
|
73
|
+
- !ruby/object:Gem::Dependency
|
74
|
+
name: activesupport
|
75
|
+
requirement: !ruby/object:Gem::Requirement
|
76
|
+
requirements:
|
77
|
+
- - ">="
|
78
|
+
- !ruby/object:Gem::Version
|
79
|
+
version: '6.1'
|
80
|
+
- - "<"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '8.0'
|
83
|
+
type: :runtime
|
84
|
+
prerelease: false
|
85
|
+
version_requirements: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '6.1'
|
90
|
+
- - "<"
|
91
|
+
- !ruby/object:Gem::Version
|
92
|
+
version: '8.0'
|
93
|
+
- !ruby/object:Gem::Dependency
|
94
|
+
name: redis
|
95
|
+
requirement: !ruby/object:Gem::Requirement
|
96
|
+
requirements:
|
97
|
+
- - ">="
|
98
|
+
- !ruby/object:Gem::Version
|
99
|
+
version: '4.8'
|
100
|
+
- - "<"
|
101
|
+
- !ruby/object:Gem::Version
|
102
|
+
version: '6.0'
|
103
|
+
type: :runtime
|
104
|
+
prerelease: false
|
105
|
+
version_requirements: !ruby/object:Gem::Requirement
|
106
|
+
requirements:
|
107
|
+
- - ">="
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: '4.8'
|
110
|
+
- - "<"
|
111
|
+
- !ruby/object:Gem::Version
|
112
|
+
version: '6.0'
|
113
|
+
- !ruby/object:Gem::Dependency
|
114
|
+
name: bundler
|
115
|
+
requirement: !ruby/object:Gem::Requirement
|
116
|
+
requirements:
|
117
|
+
- - ">="
|
118
|
+
- !ruby/object:Gem::Version
|
119
|
+
version: '0'
|
120
|
+
type: :development
|
121
|
+
prerelease: false
|
122
|
+
version_requirements: !ruby/object:Gem::Requirement
|
123
|
+
requirements:
|
124
|
+
- - ">="
|
125
|
+
- !ruby/object:Gem::Version
|
126
|
+
version: '0'
|
127
|
+
- !ruby/object:Gem::Dependency
|
128
|
+
name: factory_bot
|
129
|
+
requirement: !ruby/object:Gem::Requirement
|
130
|
+
requirements:
|
131
|
+
- - ">="
|
132
|
+
- !ruby/object:Gem::Version
|
133
|
+
version: '0'
|
134
|
+
type: :development
|
135
|
+
prerelease: false
|
136
|
+
version_requirements: !ruby/object:Gem::Requirement
|
137
|
+
requirements:
|
138
|
+
- - ">="
|
139
|
+
- !ruby/object:Gem::Version
|
140
|
+
version: '0'
|
141
|
+
- !ruby/object:Gem::Dependency
|
142
|
+
name: guard
|
143
|
+
requirement: !ruby/object:Gem::Requirement
|
144
|
+
requirements:
|
145
|
+
- - ">="
|
146
|
+
- !ruby/object:Gem::Version
|
147
|
+
version: '0'
|
148
|
+
type: :development
|
149
|
+
prerelease: false
|
150
|
+
version_requirements: !ruby/object:Gem::Requirement
|
151
|
+
requirements:
|
152
|
+
- - ">="
|
153
|
+
- !ruby/object:Gem::Version
|
154
|
+
version: '0'
|
155
|
+
- !ruby/object:Gem::Dependency
|
156
|
+
name: guard-rspec
|
157
|
+
requirement: !ruby/object:Gem::Requirement
|
158
|
+
requirements:
|
159
|
+
- - ">="
|
160
|
+
- !ruby/object:Gem::Version
|
161
|
+
version: '0'
|
162
|
+
type: :development
|
163
|
+
prerelease: false
|
164
|
+
version_requirements: !ruby/object:Gem::Requirement
|
165
|
+
requirements:
|
166
|
+
- - ">="
|
167
|
+
- !ruby/object:Gem::Version
|
168
|
+
version: '0'
|
169
|
+
- !ruby/object:Gem::Dependency
|
170
|
+
name: pry
|
171
|
+
requirement: !ruby/object:Gem::Requirement
|
172
|
+
requirements:
|
173
|
+
- - ">="
|
174
|
+
- !ruby/object:Gem::Version
|
175
|
+
version: '0'
|
176
|
+
type: :development
|
177
|
+
prerelease: false
|
178
|
+
version_requirements: !ruby/object:Gem::Requirement
|
179
|
+
requirements:
|
180
|
+
- - ">="
|
181
|
+
- !ruby/object:Gem::Version
|
182
|
+
version: '0'
|
183
|
+
- !ruby/object:Gem::Dependency
|
184
|
+
name: rake
|
185
|
+
requirement: !ruby/object:Gem::Requirement
|
186
|
+
requirements:
|
187
|
+
- - ">="
|
188
|
+
- !ruby/object:Gem::Version
|
189
|
+
version: '0'
|
190
|
+
type: :development
|
191
|
+
prerelease: false
|
192
|
+
version_requirements: !ruby/object:Gem::Requirement
|
193
|
+
requirements:
|
194
|
+
- - ">="
|
195
|
+
- !ruby/object:Gem::Version
|
196
|
+
version: '0'
|
197
|
+
- !ruby/object:Gem::Dependency
|
198
|
+
name: rspec
|
199
|
+
requirement: !ruby/object:Gem::Requirement
|
200
|
+
requirements:
|
201
|
+
- - ">="
|
202
|
+
- !ruby/object:Gem::Version
|
203
|
+
version: '0'
|
204
|
+
type: :development
|
205
|
+
prerelease: false
|
206
|
+
version_requirements: !ruby/object:Gem::Requirement
|
207
|
+
requirements:
|
208
|
+
- - ">="
|
209
|
+
- !ruby/object:Gem::Version
|
210
|
+
version: '0'
|
211
|
+
- !ruby/object:Gem::Dependency
|
212
|
+
name: rspec-rails
|
213
|
+
requirement: !ruby/object:Gem::Requirement
|
214
|
+
requirements:
|
215
|
+
- - ">="
|
216
|
+
- !ruby/object:Gem::Version
|
217
|
+
version: '0'
|
218
|
+
type: :development
|
219
|
+
prerelease: false
|
220
|
+
version_requirements: !ruby/object:Gem::Requirement
|
221
|
+
requirements:
|
222
|
+
- - ">="
|
223
|
+
- !ruby/object:Gem::Version
|
224
|
+
version: '0'
|
225
|
+
- !ruby/object:Gem::Dependency
|
226
|
+
name: rspec_junit_formatter
|
227
|
+
requirement: !ruby/object:Gem::Requirement
|
228
|
+
requirements:
|
229
|
+
- - ">="
|
230
|
+
- !ruby/object:Gem::Version
|
231
|
+
version: '0'
|
232
|
+
type: :development
|
233
|
+
prerelease: false
|
234
|
+
version_requirements: !ruby/object:Gem::Requirement
|
235
|
+
requirements:
|
236
|
+
- - ">="
|
237
|
+
- !ruby/object:Gem::Version
|
238
|
+
version: '0'
|
239
|
+
- !ruby/object:Gem::Dependency
|
240
|
+
name: sqlite3
|
241
|
+
requirement: !ruby/object:Gem::Requirement
|
242
|
+
requirements:
|
243
|
+
- - ">="
|
244
|
+
- !ruby/object:Gem::Version
|
245
|
+
version: '0'
|
246
|
+
type: :development
|
247
|
+
prerelease: false
|
248
|
+
version_requirements: !ruby/object:Gem::Requirement
|
249
|
+
requirements:
|
250
|
+
- - ">="
|
251
|
+
- !ruby/object:Gem::Version
|
252
|
+
version: '0'
|
253
|
+
- !ruby/object:Gem::Dependency
|
254
|
+
name: standard
|
255
|
+
requirement: !ruby/object:Gem::Requirement
|
256
|
+
requirements:
|
257
|
+
- - ">="
|
258
|
+
- !ruby/object:Gem::Version
|
259
|
+
version: '0'
|
260
|
+
type: :development
|
261
|
+
prerelease: false
|
262
|
+
version_requirements: !ruby/object:Gem::Requirement
|
263
|
+
requirements:
|
264
|
+
- - ">="
|
265
|
+
- !ruby/object:Gem::Version
|
266
|
+
version: '0'
|
267
|
+
- !ruby/object:Gem::Dependency
|
268
|
+
name: yard
|
269
|
+
requirement: !ruby/object:Gem::Requirement
|
270
|
+
requirements:
|
271
|
+
- - ">="
|
272
|
+
- !ruby/object:Gem::Version
|
273
|
+
version: '0'
|
274
|
+
type: :development
|
275
|
+
prerelease: false
|
276
|
+
version_requirements: !ruby/object:Gem::Requirement
|
277
|
+
requirements:
|
278
|
+
- - ">="
|
279
|
+
- !ruby/object:Gem::Version
|
280
|
+
version: '0'
|
13
281
|
description: Provides tools for managing resource-efficient backfills of large datasets
|
14
282
|
via ActiveJob
|
15
283
|
email:
|
@@ -17,10 +285,40 @@ email:
|
|
17
285
|
executables: []
|
18
286
|
extensions: []
|
19
287
|
extra_rdoc_files: []
|
20
|
-
files:
|
288
|
+
files:
|
289
|
+
- ".circleci/config.yml"
|
290
|
+
- ".github/CODEOWNERS"
|
291
|
+
- ".gitignore"
|
292
|
+
- ".rspec"
|
293
|
+
- ".ruby-version"
|
294
|
+
- ".travis.yml"
|
295
|
+
- CHANGELOG.md
|
296
|
+
- CONTRIBUTING.md
|
297
|
+
- Gemfile
|
298
|
+
- Gemfile.lock
|
299
|
+
- Guardfile
|
300
|
+
- LICENSE.txt
|
301
|
+
- README.md
|
302
|
+
- Rakefile
|
303
|
+
- bin/console
|
304
|
+
- bin/setup
|
305
|
+
- lib/super_spreader.rb
|
306
|
+
- lib/super_spreader/batch_helper.rb
|
307
|
+
- lib/super_spreader/peak_schedule.rb
|
308
|
+
- lib/super_spreader/redis_model.rb
|
309
|
+
- lib/super_spreader/scheduler_config.rb
|
310
|
+
- lib/super_spreader/scheduler_job.rb
|
311
|
+
- lib/super_spreader/spread_tracker.rb
|
312
|
+
- lib/super_spreader/spreader.rb
|
313
|
+
- lib/super_spreader/stop_signal.rb
|
314
|
+
- lib/super_spreader/version.rb
|
315
|
+
- super_spreader.gemspec
|
21
316
|
homepage: https://github.com/doximity/super_spreader
|
22
317
|
licenses: []
|
23
|
-
metadata:
|
318
|
+
metadata:
|
319
|
+
homepage_uri: https://github.com/doximity/super_spreader
|
320
|
+
source_code_uri: https://github.com/doximity/super_spreader
|
321
|
+
changelog_uri: https://github.com/doximity/super_spreader/blob/main/CHANGELOG.md
|
24
322
|
post_install_message:
|
25
323
|
rdoc_options: []
|
26
324
|
require_paths:
|
@@ -36,7 +334,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
36
334
|
- !ruby/object:Gem::Version
|
37
335
|
version: '0'
|
38
336
|
requirements: []
|
39
|
-
rubygems_version: 3.
|
337
|
+
rubygems_version: 3.4.10
|
40
338
|
signing_key:
|
41
339
|
specification_version: 4
|
42
340
|
summary: ActiveJob-based backfill orchestration library
|