sidekiq 5.1.3 → 6.4.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of sidekiq might be problematic. Click here for more details.

Files changed (106) hide show
  1. checksums.yaml +5 -5
  2. data/Changes.md +391 -1
  3. data/LICENSE +3 -3
  4. data/README.md +23 -34
  5. data/bin/sidekiq +27 -3
  6. data/bin/sidekiqload +68 -62
  7. data/bin/sidekiqmon +8 -0
  8. data/lib/generators/sidekiq/job_generator.rb +57 -0
  9. data/lib/generators/sidekiq/templates/{worker.rb.erb → job.rb.erb} +2 -2
  10. data/lib/generators/sidekiq/templates/{worker_spec.rb.erb → job_spec.rb.erb} +1 -1
  11. data/lib/generators/sidekiq/templates/{worker_test.rb.erb → job_test.rb.erb} +1 -1
  12. data/lib/sidekiq/api.rb +344 -243
  13. data/lib/sidekiq/cli.rb +209 -221
  14. data/lib/sidekiq/client.rb +62 -64
  15. data/lib/sidekiq/delay.rb +7 -6
  16. data/lib/sidekiq/exception_handler.rb +10 -12
  17. data/lib/sidekiq/extensions/action_mailer.rb +13 -22
  18. data/lib/sidekiq/extensions/active_record.rb +13 -10
  19. data/lib/sidekiq/extensions/class_methods.rb +14 -11
  20. data/lib/sidekiq/extensions/generic_proxy.rb +6 -4
  21. data/lib/sidekiq/fetch.rb +40 -32
  22. data/lib/sidekiq/job.rb +13 -0
  23. data/lib/sidekiq/job_logger.rb +35 -9
  24. data/lib/sidekiq/job_retry.rb +88 -68
  25. data/lib/sidekiq/job_util.rb +65 -0
  26. data/lib/sidekiq/launcher.rb +170 -73
  27. data/lib/sidekiq/logger.rb +170 -0
  28. data/lib/sidekiq/manager.rb +18 -22
  29. data/lib/sidekiq/middleware/chain.rb +20 -8
  30. data/lib/sidekiq/middleware/current_attributes.rb +57 -0
  31. data/lib/sidekiq/middleware/i18n.rb +5 -7
  32. data/lib/sidekiq/monitor.rb +133 -0
  33. data/lib/sidekiq/paginator.rb +20 -16
  34. data/lib/sidekiq/processor.rb +135 -83
  35. data/lib/sidekiq/rails.rb +42 -38
  36. data/lib/sidekiq/redis_connection.rb +49 -30
  37. data/lib/sidekiq/scheduled.rb +94 -31
  38. data/lib/sidekiq/sd_notify.rb +149 -0
  39. data/lib/sidekiq/systemd.rb +24 -0
  40. data/lib/sidekiq/testing/inline.rb +2 -1
  41. data/lib/sidekiq/testing.rb +40 -31
  42. data/lib/sidekiq/util.rb +57 -15
  43. data/lib/sidekiq/version.rb +2 -1
  44. data/lib/sidekiq/web/action.rb +15 -11
  45. data/lib/sidekiq/web/application.rb +109 -74
  46. data/lib/sidekiq/web/csrf_protection.rb +180 -0
  47. data/lib/sidekiq/web/helpers.rb +117 -93
  48. data/lib/sidekiq/web/router.rb +23 -19
  49. data/lib/sidekiq/web.rb +61 -105
  50. data/lib/sidekiq/worker.rb +257 -99
  51. data/lib/sidekiq.rb +81 -46
  52. data/sidekiq.gemspec +23 -23
  53. data/web/assets/images/apple-touch-icon.png +0 -0
  54. data/web/assets/javascripts/application.js +83 -64
  55. data/web/assets/javascripts/dashboard.js +66 -75
  56. data/web/assets/stylesheets/application-dark.css +143 -0
  57. data/web/assets/stylesheets/application-rtl.css +0 -4
  58. data/web/assets/stylesheets/application.css +77 -231
  59. data/web/assets/stylesheets/bootstrap.css +2 -2
  60. data/web/locales/ar.yml +9 -2
  61. data/web/locales/de.yml +14 -2
  62. data/web/locales/en.yml +7 -1
  63. data/web/locales/es.yml +21 -5
  64. data/web/locales/fr.yml +10 -3
  65. data/web/locales/ja.yml +7 -1
  66. data/web/locales/lt.yml +83 -0
  67. data/web/locales/pl.yml +4 -4
  68. data/web/locales/ru.yml +4 -0
  69. data/web/locales/vi.yml +83 -0
  70. data/web/views/_footer.erb +1 -1
  71. data/web/views/_job_info.erb +3 -2
  72. data/web/views/_nav.erb +3 -17
  73. data/web/views/_poll_link.erb +2 -5
  74. data/web/views/_summary.erb +7 -7
  75. data/web/views/busy.erb +54 -20
  76. data/web/views/dashboard.erb +22 -14
  77. data/web/views/dead.erb +3 -3
  78. data/web/views/layout.erb +4 -2
  79. data/web/views/morgue.erb +9 -6
  80. data/web/views/queue.erb +20 -10
  81. data/web/views/queues.erb +11 -3
  82. data/web/views/retries.erb +14 -7
  83. data/web/views/retry.erb +3 -3
  84. data/web/views/scheduled.erb +5 -2
  85. metadata +39 -136
  86. data/.github/contributing.md +0 -32
  87. data/.github/issue_template.md +0 -11
  88. data/.gitignore +0 -13
  89. data/.travis.yml +0 -14
  90. data/3.0-Upgrade.md +0 -70
  91. data/4.0-Upgrade.md +0 -53
  92. data/5.0-Upgrade.md +0 -56
  93. data/COMM-LICENSE +0 -95
  94. data/Ent-Changes.md +0 -216
  95. data/Gemfile +0 -8
  96. data/Pro-2.0-Upgrade.md +0 -138
  97. data/Pro-3.0-Upgrade.md +0 -44
  98. data/Pro-4.0-Upgrade.md +0 -35
  99. data/Pro-Changes.md +0 -729
  100. data/Rakefile +0 -8
  101. data/bin/sidekiqctl +0 -99
  102. data/code_of_conduct.md +0 -50
  103. data/lib/generators/sidekiq/worker_generator.rb +0 -49
  104. data/lib/sidekiq/core_ext.rb +0 -1
  105. data/lib/sidekiq/logging.rb +0 -122
  106. data/lib/sidekiq/middleware/server/active_record.rb +0 -23
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.1.3
4
+ version: 6.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Perham
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-04-02 00:00:00.000000000 Z
11
+ date: 2022-02-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: redis
@@ -16,176 +16,65 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 3.3.5
20
- - - "<"
21
- - !ruby/object:Gem::Version
22
- version: '5'
19
+ version: 4.2.0
23
20
  type: :runtime
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
24
  - - ">="
28
25
  - !ruby/object:Gem::Version
29
- version: 3.3.5
30
- - - "<"
31
- - !ruby/object:Gem::Version
32
- version: '5'
26
+ version: 4.2.0
33
27
  - !ruby/object:Gem::Dependency
34
28
  name: connection_pool
35
29
  requirement: !ruby/object:Gem::Requirement
36
30
  requirements:
37
- - - "~>"
38
- - !ruby/object:Gem::Version
39
- version: '2.2'
40
31
  - - ">="
41
32
  - !ruby/object:Gem::Version
42
- version: 2.2.0
33
+ version: 2.2.2
43
34
  type: :runtime
44
35
  prerelease: false
45
36
  version_requirements: !ruby/object:Gem::Requirement
46
37
  requirements:
47
- - - "~>"
48
- - !ruby/object:Gem::Version
49
- version: '2.2'
50
38
  - - ">="
51
39
  - !ruby/object:Gem::Version
52
- version: 2.2.0
40
+ version: 2.2.2
53
41
  - !ruby/object:Gem::Dependency
54
- name: concurrent-ruby
42
+ name: rack
55
43
  requirement: !ruby/object:Gem::Requirement
56
44
  requirements:
57
45
  - - "~>"
58
46
  - !ruby/object:Gem::Version
59
- version: '1.0'
47
+ version: '2.0'
60
48
  type: :runtime
61
49
  prerelease: false
62
50
  version_requirements: !ruby/object:Gem::Requirement
63
51
  requirements:
64
52
  - - "~>"
65
53
  - !ruby/object:Gem::Version
66
- version: '1.0'
67
- - !ruby/object:Gem::Dependency
68
- name: rack-protection
69
- requirement: !ruby/object:Gem::Requirement
70
- requirements:
71
- - - ">="
72
- - !ruby/object:Gem::Version
73
- version: 1.5.0
74
- type: :runtime
75
- prerelease: false
76
- version_requirements: !ruby/object:Gem::Requirement
77
- requirements:
78
- - - ">="
79
- - !ruby/object:Gem::Version
80
- version: 1.5.0
81
- - !ruby/object:Gem::Dependency
82
- name: redis-namespace
83
- requirement: !ruby/object:Gem::Requirement
84
- requirements:
85
- - - "~>"
86
- - !ruby/object:Gem::Version
87
- version: '1.5'
88
- - - ">="
89
- - !ruby/object:Gem::Version
90
- version: 1.5.2
91
- type: :development
92
- prerelease: false
93
- version_requirements: !ruby/object:Gem::Requirement
94
- requirements:
95
- - - "~>"
96
- - !ruby/object:Gem::Version
97
- version: '1.5'
98
- - - ">="
99
- - !ruby/object:Gem::Version
100
- version: 1.5.2
101
- - !ruby/object:Gem::Dependency
102
- name: minitest
103
- requirement: !ruby/object:Gem::Requirement
104
- requirements:
105
- - - "~>"
106
- - !ruby/object:Gem::Version
107
- version: '5.10'
108
- - - ">="
109
- - !ruby/object:Gem::Version
110
- version: 5.10.1
111
- type: :development
112
- prerelease: false
113
- version_requirements: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '5.10'
118
- - - ">="
119
- - !ruby/object:Gem::Version
120
- version: 5.10.1
121
- - !ruby/object:Gem::Dependency
122
- name: rake
123
- requirement: !ruby/object:Gem::Requirement
124
- requirements:
125
- - - "~>"
126
- - !ruby/object:Gem::Version
127
- version: '10.0'
128
- type: :development
129
- prerelease: false
130
- version_requirements: !ruby/object:Gem::Requirement
131
- requirements:
132
- - - "~>"
133
- - !ruby/object:Gem::Version
134
- version: '10.0'
135
- - !ruby/object:Gem::Dependency
136
- name: rails
137
- requirement: !ruby/object:Gem::Requirement
138
- requirements:
139
- - - ">="
140
- - !ruby/object:Gem::Version
141
- version: 3.2.0
142
- type: :development
143
- prerelease: false
144
- version_requirements: !ruby/object:Gem::Requirement
145
- requirements:
146
- - - ">="
147
- - !ruby/object:Gem::Version
148
- version: 3.2.0
54
+ version: '2.0'
149
55
  description: Simple, efficient background processing for Ruby.
150
56
  email:
151
57
  - mperham@gmail.com
152
58
  executables:
153
59
  - sidekiq
154
- - sidekiqctl
60
+ - sidekiqmon
155
61
  extensions: []
156
62
  extra_rdoc_files: []
157
63
  files:
158
- - ".github/contributing.md"
159
- - ".github/issue_template.md"
160
- - ".gitignore"
161
- - ".travis.yml"
162
- - 3.0-Upgrade.md
163
- - 4.0-Upgrade.md
164
- - 5.0-Upgrade.md
165
- - COMM-LICENSE
166
64
  - Changes.md
167
- - Ent-Changes.md
168
- - Gemfile
169
65
  - LICENSE
170
- - Pro-2.0-Upgrade.md
171
- - Pro-3.0-Upgrade.md
172
- - Pro-4.0-Upgrade.md
173
- - Pro-Changes.md
174
66
  - README.md
175
- - Rakefile
176
67
  - bin/sidekiq
177
- - bin/sidekiqctl
178
68
  - bin/sidekiqload
179
- - code_of_conduct.md
180
- - lib/generators/sidekiq/templates/worker.rb.erb
181
- - lib/generators/sidekiq/templates/worker_spec.rb.erb
182
- - lib/generators/sidekiq/templates/worker_test.rb.erb
183
- - lib/generators/sidekiq/worker_generator.rb
69
+ - bin/sidekiqmon
70
+ - lib/generators/sidekiq/job_generator.rb
71
+ - lib/generators/sidekiq/templates/job.rb.erb
72
+ - lib/generators/sidekiq/templates/job_spec.rb.erb
73
+ - lib/generators/sidekiq/templates/job_test.rb.erb
184
74
  - lib/sidekiq.rb
185
75
  - lib/sidekiq/api.rb
186
76
  - lib/sidekiq/cli.rb
187
77
  - lib/sidekiq/client.rb
188
- - lib/sidekiq/core_ext.rb
189
78
  - lib/sidekiq/delay.rb
190
79
  - lib/sidekiq/exception_handler.rb
191
80
  - lib/sidekiq/extensions/action_mailer.rb
@@ -193,19 +82,24 @@ files:
193
82
  - lib/sidekiq/extensions/class_methods.rb
194
83
  - lib/sidekiq/extensions/generic_proxy.rb
195
84
  - lib/sidekiq/fetch.rb
85
+ - lib/sidekiq/job.rb
196
86
  - lib/sidekiq/job_logger.rb
197
87
  - lib/sidekiq/job_retry.rb
88
+ - lib/sidekiq/job_util.rb
198
89
  - lib/sidekiq/launcher.rb
199
- - lib/sidekiq/logging.rb
90
+ - lib/sidekiq/logger.rb
200
91
  - lib/sidekiq/manager.rb
201
92
  - lib/sidekiq/middleware/chain.rb
93
+ - lib/sidekiq/middleware/current_attributes.rb
202
94
  - lib/sidekiq/middleware/i18n.rb
203
- - lib/sidekiq/middleware/server/active_record.rb
95
+ - lib/sidekiq/monitor.rb
204
96
  - lib/sidekiq/paginator.rb
205
97
  - lib/sidekiq/processor.rb
206
98
  - lib/sidekiq/rails.rb
207
99
  - lib/sidekiq/redis_connection.rb
208
100
  - lib/sidekiq/scheduled.rb
101
+ - lib/sidekiq/sd_notify.rb
102
+ - lib/sidekiq/systemd.rb
209
103
  - lib/sidekiq/testing.rb
210
104
  - lib/sidekiq/testing/inline.rb
211
105
  - lib/sidekiq/util.rb
@@ -213,15 +107,18 @@ files:
213
107
  - lib/sidekiq/web.rb
214
108
  - lib/sidekiq/web/action.rb
215
109
  - lib/sidekiq/web/application.rb
110
+ - lib/sidekiq/web/csrf_protection.rb
216
111
  - lib/sidekiq/web/helpers.rb
217
112
  - lib/sidekiq/web/router.rb
218
113
  - lib/sidekiq/worker.rb
219
114
  - sidekiq.gemspec
115
+ - web/assets/images/apple-touch-icon.png
220
116
  - web/assets/images/favicon.ico
221
117
  - web/assets/images/logo.png
222
118
  - web/assets/images/status.png
223
119
  - web/assets/javascripts/application.js
224
120
  - web/assets/javascripts/dashboard.js
121
+ - web/assets/stylesheets/application-dark.css
225
122
  - web/assets/stylesheets/application-rtl.css
226
123
  - web/assets/stylesheets/application.css
227
124
  - web/assets/stylesheets/bootstrap-rtl.min.css
@@ -240,6 +137,7 @@ files:
240
137
  - web/locales/it.yml
241
138
  - web/locales/ja.yml
242
139
  - web/locales/ko.yml
140
+ - web/locales/lt.yml
243
141
  - web/locales/nb.yml
244
142
  - web/locales/nl.yml
245
143
  - web/locales/pl.yml
@@ -250,6 +148,7 @@ files:
250
148
  - web/locales/ta.yml
251
149
  - web/locales/uk.yml
252
150
  - web/locales/ur.yml
151
+ - web/locales/vi.yml
253
152
  - web/locales/zh-cn.yml
254
153
  - web/locales/zh-tw.yml
255
154
  - web/views/_footer.erb
@@ -270,11 +169,16 @@ files:
270
169
  - web/views/retry.erb
271
170
  - web/views/scheduled.erb
272
171
  - web/views/scheduled_job_info.erb
273
- homepage: http://sidekiq.org
172
+ homepage: https://sidekiq.org
274
173
  licenses:
275
174
  - LGPL-3.0
276
- metadata: {}
277
- post_install_message:
175
+ metadata:
176
+ homepage_uri: https://sidekiq.org
177
+ bug_tracker_uri: https://github.com/mperham/sidekiq/issues
178
+ documentation_uri: https://github.com/mperham/sidekiq/wiki
179
+ changelog_uri: https://github.com/mperham/sidekiq/blob/main/Changes.md
180
+ source_code_uri: https://github.com/mperham/sidekiq
181
+ post_install_message:
278
182
  rdoc_options: []
279
183
  require_paths:
280
184
  - lib
@@ -282,16 +186,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
282
186
  requirements:
283
187
  - - ">="
284
188
  - !ruby/object:Gem::Version
285
- version: 2.2.2
189
+ version: 2.5.0
286
190
  required_rubygems_version: !ruby/object:Gem::Requirement
287
191
  requirements:
288
192
  - - ">="
289
193
  - !ruby/object:Gem::Version
290
194
  version: '0'
291
195
  requirements: []
292
- rubyforge_project:
293
- rubygems_version: 2.6.13
294
- signing_key:
196
+ rubygems_version: 3.2.32
197
+ signing_key:
295
198
  specification_version: 4
296
199
  summary: Simple, efficient background processing for Ruby
297
200
  test_files: []
@@ -1,32 +0,0 @@
1
- # Contributing
2
-
3
- ## Issues
4
-
5
- When opening an issue:
6
-
7
- * include the full **backtrace** with your error
8
- * include your Sidekiq initializer
9
- * list versions you are using: Ruby, Rails, Sidekiq, OS, etc.
10
-
11
- It's always better to include more info rather than less.
12
-
13
- ## Code
14
-
15
- It's always best to open an issue before investing a lot of time into a
16
- fix or new functionality. Functionality must meet my design goals and
17
- vision for the project to be accepted; I would be happy to discuss how
18
- your idea can best fit into Sidekiq.
19
-
20
- ## Legal
21
-
22
- By submitting a Pull Request, you disavow any rights or claims to any changes
23
- submitted to the Sidekiq project and assign the copyright of
24
- those changes to Contributed Systems LLC.
25
-
26
- If you cannot or do not want to reassign those rights (your employment
27
- contract for your employer may not allow this), you should not submit a PR.
28
- Open an issue and someone else can do the work.
29
-
30
- This is a legal way of saying "If you submit a PR to us, that code becomes ours".
31
- 99.9% of the time that's what you intend anyways; we hope it doesn't scare you
32
- away from contributing.
@@ -1,11 +0,0 @@
1
- Ruby version:
2
- Sidekiq / Pro / Enterprise version(s):
3
-
4
- Please include your initializer and any error message with the full backtrace.
5
-
6
- Are you using an old version?
7
- Have you checked the changelogs to see if your issue has been fixed in a later version?
8
-
9
- https://github.com/mperham/sidekiq/blob/master/Changes.md
10
- https://github.com/mperham/sidekiq/blob/master/Pro-Changes.md
11
- https://github.com/mperham/sidekiq/blob/master/Ent-Changes.md
data/.gitignore DELETED
@@ -1,13 +0,0 @@
1
- .rvmrc
2
- .ruby-version
3
- tags
4
- Gemfile.lock
5
- *.swp
6
- dump.rdb
7
- .rbx
8
- coverage/
9
- vendor/
10
- .bundle/
11
- .sass-cache/
12
- tmp/
13
- pkg/*.gem
data/.travis.yml DELETED
@@ -1,14 +0,0 @@
1
- language: ruby
2
- sudo: false
3
- cache: bundler
4
- services:
5
- - redis-server
6
- before_install:
7
- - gem install bundler
8
- - gem update bundler
9
- rvm:
10
- - 2.2.10
11
- - 2.3.7
12
- - 2.4.4
13
- - 2.5.1
14
- - jruby-9.1.16.0
data/3.0-Upgrade.md DELETED
@@ -1,70 +0,0 @@
1
- # Upgrading to Sidekiq 3.0
2
-
3
- Sidekiq 3.0 brings several new features but also removes old APIs and
4
- changes a few data elements in Redis. To upgrade cleanly:
5
-
6
- * Upgrade to the latest Sidekiq 2.x and run it for a few weeks.
7
- `gem 'sidekiq', '< 3'`
8
- This is only needed if you have retries pending.
9
- * 3rd party gems which use **client-side middleware** will need to update
10
- due to an API change. The Redis connection for a particular job is
11
- passed thru the middleware to handle sharding where jobs can
12
- be pushed to different redis server instances.
13
-
14
- `def call(worker_class, msg, queue, redis_pool)`
15
-
16
- Client-side middleware should use `redis_pool.with { |conn| ... }` to
17
- perform Redis operations and **not** `Sidekiq.redis`.
18
- * If you used the capistrano integration, you'll need to pull in the
19
- new [capistrano-sidekiq](https://github.com/seuros/capistrano-sidekiq)
20
- gem and use it in your deploy.rb.
21
- * API changes:
22
- - `Sidekiq::Client.registered_workers` replaced by `Sidekiq::Workers.new`
23
- - `Sidekiq::Client.registered_queues` replaced by `Sidekiq::Queue.all`
24
- - `Sidekiq::Worker#retries_exhausted` replaced by `Sidekiq::Worker.sidekiq_retries_exhausted`
25
- - `Sidekiq::Workers#each` has changed significantly with a reworking
26
- of Sidekiq's internal process/thread data model.
27
- * `sidekiq/api` is no longer automatically required. If your code uses
28
- the API, you will need to require it.
29
- * Redis-to-Go is no longer transparently activated on Heroku so as to not play
30
- favorites with any particular Redis service. You need to set a config option
31
- for your app:
32
- `heroku config:set REDIS_PROVIDER=REDISTOGO_URL`. You may also use
33
- the generic `REDIS_URL`. See
34
- [Advanced Options: Setting the Location of your Redis server][1]
35
- for details.
36
- * Anyone using Airbrake, Honeybadger, Exceptional or ExceptionNotifier
37
- will need to update their error gem version to the latest to pull in
38
- Sidekiq support. Sidekiq will not provide explicit support for these
39
- services so as to not play favorites with any particular error service.
40
- * MRI 1.9 is no longer officially supported. Sidekiq's official
41
- support policy is to support the current and previous major releases
42
- of MRI and Rails. As of February 2014, that's MRI 2.1, MRI 2.0, JRuby 1.7, Rails 4.0
43
- and Rails 3.2. I will consider PRs to fix issues found by users for
44
- other platforms/versions.
45
-
46
- ## Error Service Providers
47
-
48
- If you previously provided a middleware to capture job errors, you
49
- should instead provide a global error handler with Sidekiq 3.0. This
50
- ensures **any** error within Sidekiq will be logged appropriately, not
51
- just during job execution.
52
-
53
- ```ruby
54
- if Sidekiq::VERSION < '3'
55
- # old behavior
56
- Sidekiq.configure_server do |config|
57
- config.server_middleware do |chain|
58
- chain.add MyErrorService::Middleware
59
- end
60
- end
61
- else
62
- Sidekiq.configure_server do |config|
63
- config.error_handlers << proc {|ex,context| MyErrorService.notify(ex, context) }
64
- end
65
- end
66
- ```
67
-
68
- Your error handler must respond to `call(exception, context_hash)`.
69
-
70
- [1]: https://github.com/mperham/sidekiq/wiki/Advanced-Options#via-env-variable
data/4.0-Upgrade.md DELETED
@@ -1,53 +0,0 @@
1
- # Welcome to Sidekiq 4.0!
2
-
3
- Sidekiq 4.0 contains a redesigned, more efficient core with less overhead per job.
4
- See my blog for [an overview of Sidekiq 4's higher performance](http://www.mikeperham.com/2015/10/14/optimizing-sidekiq/).
5
-
6
- ## What's New
7
-
8
- * Sidekiq no longer uses Celluloid. If your application code uses Celluloid,
9
- you will need to pull it in yourself.
10
-
11
- * `redis-namespace` has been removed from Sidekiq's gem dependencies. If
12
- you want to use namespacing ([and I strongly urge you not to](http://www.mikeperham.com/2015/09/24/storing-data-with-redis/)), you'll need to add the gem to your Gemfile:
13
- ```ruby
14
- gem 'redis-namespace'
15
- ```
16
-
17
- * **Redis 2.8.0 or greater is required.** Redis 2.8 was released two years
18
- ago and contains **many** useful features which Sidekiq couldn't
19
- leverage until now. **Redis 3.0.3 or greater is recommended** for large
20
- scale use [#2431](https://github.com/mperham/sidekiq/issues/2431).
21
-
22
- * Jobs are now fetched from Redis in parallel, making Sidekiq more
23
- resilient to high network latency. This means that Sidekiq requires
24
- more Redis connections per process. You must have a minimum of
25
- `concurrency + 2` connections in your pool or Sidekiq will exit.
26
- When in doubt, let Sidekiq size the connection pool for you.
27
-
28
- * Worker data is no longer updated in real-time but rather upon every
29
- heartbeat. Don't expect the `Sidekiq::Workers` API to be millisecond-precise.
30
-
31
- * There's a new testing API based off the `Sidekiq::Queues` namespace. All
32
- assertions made against the Worker class still work as expected.
33
- ```ruby
34
- assert_equal 0, Sidekiq::Queues["default"].size
35
- HardWorker.perform_async("log")
36
- assert_equal 1, Sidekiq::Queues["default"].size
37
- assert_equal "log", Sidekiq::Queues["default"].first['args'][0]
38
- Sidekiq::Queues.clear_all
39
- ```
40
-
41
- ## Upgrade
42
-
43
- First, make sure you are using Redis 2.8 or greater. Next:
44
-
45
- * Upgrade to the latest Sidekiq 3.x.
46
- ```ruby
47
- gem 'sidekiq', '< 4'
48
- ```
49
- * Fix any deprecation warnings you see.
50
- * Upgrade to 4.x.
51
- ```ruby
52
- gem 'sidekiq', '< 5'
53
- ```
data/5.0-Upgrade.md DELETED
@@ -1,56 +0,0 @@
1
- # Welcome to Sidekiq 5.0!
2
-
3
- Sidekiq 5.0 contains a reworked job dispatch and execution core to integrate
4
- better with the new Rails 5.0 Executor. It also drops support for older
5
- versions of Ruby and Rails and adds support for RTL languages in the Web UI.
6
-
7
- ## What's New
8
-
9
- * Integrate job logging and retry logic directly in with the job
10
- execution logic in Sidekiq::Processor. Previously this logic was
11
- defined as middleware. In Rails 5.0, ActiveSupport::Executor handles ActiveRecord
12
- connection management, job callbacks, development mode class loading,
13
- etc. Because of its extensive responsibilities, the Executor can't be
14
- integrated as Sidekiq middleware; the logging/retry logic had to be pulled out
15
- too. Sidekiq 4.2 had a hack to make it work but this redesign provides
16
- a cleaner integration. [#3235]
17
- * The Delayed Extensions `delay`, `delay_in` and `delay_until` APIs are
18
- no longer available by default. The extensions allow you to marshal
19
- job arguments as YAML, leading to cases where job payloads could be many
20
- 100s of KB or larger if not careful, leading to Redis networking
21
- timeouts or other problems. As noted in the Best Practices wiki page,
22
- Sidekiq is designed for jobs with small, simple arguments.
23
-
24
- Add this line to your initializer to re-enable them and get the old behavior:
25
- ```ruby
26
- Sidekiq::Extensions.enable_delay!
27
- ```
28
- The old `Sidekiq.remove_delay!` API has been removed as it is now the default. [#3299]
29
- * Sidekiq's quiet signal is now `TSTP` (think of it as **T**hread
30
- **ST**o**P**) instead of USR1 as USR1 is not available on JRuby.
31
- USR1 will continue to be supported in Sidekiq 5.x for backwards
32
- compatibility and will be removed in Sidekiq 6.x. [#3302]
33
- * The Web UI is now bi-directional - it can render either LTR
34
- (left-to-right) or RTL languages. With this change, **Farsi, Arabic,
35
- Hebrew and Urdu** are officially supported. [#3381]
36
- * Jobs which can't be parsed due to invalid JSON are now pushed
37
- immediately to the Dead set since they require manual intervention and
38
- will never execute successfully as is. The Web UI has been updated to
39
- more gracefully display these jobs. [#3296]
40
- * **Rails 3.2** is no longer supported.
41
- * **Ruby 2.0 and Ruby 2.1** are no longer supported. Ruby 2.2.2+ is required.
42
-
43
- ## Upgrade
44
-
45
- As always, please upgrade Sidekiq **one major version at a time**.
46
- If you are already running Sidekiq 4.x, then:
47
-
48
- * Upgrade to the latest Sidekiq 4.x.
49
- ```ruby
50
- gem 'sidekiq', '< 5'
51
- ```
52
- * Fix any deprecation warnings you see.
53
- * Upgrade to 5.x.
54
- ```ruby
55
- gem 'sidekiq', '< 6'
56
- ```