sidekiq 6.1.0

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 (127) hide show
  1. checksums.yaml +7 -0
  2. data/.circleci/config.yml +71 -0
  3. data/.github/contributing.md +32 -0
  4. data/.github/issue_template.md +11 -0
  5. data/.gitignore +13 -0
  6. data/.standard.yml +20 -0
  7. data/3.0-Upgrade.md +70 -0
  8. data/4.0-Upgrade.md +53 -0
  9. data/5.0-Upgrade.md +56 -0
  10. data/6.0-Upgrade.md +72 -0
  11. data/COMM-LICENSE +97 -0
  12. data/Changes.md +1718 -0
  13. data/Ent-2.0-Upgrade.md +37 -0
  14. data/Ent-Changes.md +269 -0
  15. data/Gemfile +24 -0
  16. data/Gemfile.lock +208 -0
  17. data/LICENSE +9 -0
  18. data/Pro-2.0-Upgrade.md +138 -0
  19. data/Pro-3.0-Upgrade.md +44 -0
  20. data/Pro-4.0-Upgrade.md +35 -0
  21. data/Pro-5.0-Upgrade.md +25 -0
  22. data/Pro-Changes.md +790 -0
  23. data/README.md +94 -0
  24. data/Rakefile +10 -0
  25. data/bin/sidekiq +42 -0
  26. data/bin/sidekiqload +157 -0
  27. data/bin/sidekiqmon +8 -0
  28. data/code_of_conduct.md +50 -0
  29. data/lib/generators/sidekiq/templates/worker.rb.erb +9 -0
  30. data/lib/generators/sidekiq/templates/worker_spec.rb.erb +6 -0
  31. data/lib/generators/sidekiq/templates/worker_test.rb.erb +8 -0
  32. data/lib/generators/sidekiq/worker_generator.rb +57 -0
  33. data/lib/sidekiq.rb +262 -0
  34. data/lib/sidekiq/api.rb +960 -0
  35. data/lib/sidekiq/cli.rb +401 -0
  36. data/lib/sidekiq/client.rb +263 -0
  37. data/lib/sidekiq/delay.rb +41 -0
  38. data/lib/sidekiq/exception_handler.rb +27 -0
  39. data/lib/sidekiq/extensions/action_mailer.rb +47 -0
  40. data/lib/sidekiq/extensions/active_record.rb +43 -0
  41. data/lib/sidekiq/extensions/class_methods.rb +43 -0
  42. data/lib/sidekiq/extensions/generic_proxy.rb +31 -0
  43. data/lib/sidekiq/fetch.rb +82 -0
  44. data/lib/sidekiq/job_logger.rb +63 -0
  45. data/lib/sidekiq/job_retry.rb +262 -0
  46. data/lib/sidekiq/launcher.rb +206 -0
  47. data/lib/sidekiq/logger.rb +165 -0
  48. data/lib/sidekiq/manager.rb +135 -0
  49. data/lib/sidekiq/middleware/chain.rb +160 -0
  50. data/lib/sidekiq/middleware/i18n.rb +40 -0
  51. data/lib/sidekiq/monitor.rb +133 -0
  52. data/lib/sidekiq/paginator.rb +47 -0
  53. data/lib/sidekiq/processor.rb +280 -0
  54. data/lib/sidekiq/rails.rb +50 -0
  55. data/lib/sidekiq/redis_connection.rb +146 -0
  56. data/lib/sidekiq/scheduled.rb +173 -0
  57. data/lib/sidekiq/sd_notify.rb +149 -0
  58. data/lib/sidekiq/systemd.rb +24 -0
  59. data/lib/sidekiq/testing.rb +344 -0
  60. data/lib/sidekiq/testing/inline.rb +30 -0
  61. data/lib/sidekiq/util.rb +67 -0
  62. data/lib/sidekiq/version.rb +5 -0
  63. data/lib/sidekiq/web.rb +213 -0
  64. data/lib/sidekiq/web/action.rb +93 -0
  65. data/lib/sidekiq/web/application.rb +357 -0
  66. data/lib/sidekiq/web/csrf_protection.rb +153 -0
  67. data/lib/sidekiq/web/helpers.rb +333 -0
  68. data/lib/sidekiq/web/router.rb +101 -0
  69. data/lib/sidekiq/worker.rb +244 -0
  70. data/sidekiq.gemspec +20 -0
  71. data/web/assets/images/favicon.ico +0 -0
  72. data/web/assets/images/logo.png +0 -0
  73. data/web/assets/images/status.png +0 -0
  74. data/web/assets/javascripts/application.js +95 -0
  75. data/web/assets/javascripts/dashboard.js +296 -0
  76. data/web/assets/stylesheets/application-dark.css +133 -0
  77. data/web/assets/stylesheets/application-rtl.css +246 -0
  78. data/web/assets/stylesheets/application.css +1158 -0
  79. data/web/assets/stylesheets/bootstrap-rtl.min.css +9 -0
  80. data/web/assets/stylesheets/bootstrap.css +5 -0
  81. data/web/locales/ar.yml +81 -0
  82. data/web/locales/cs.yml +78 -0
  83. data/web/locales/da.yml +68 -0
  84. data/web/locales/de.yml +81 -0
  85. data/web/locales/el.yml +68 -0
  86. data/web/locales/en.yml +83 -0
  87. data/web/locales/es.yml +70 -0
  88. data/web/locales/fa.yml +80 -0
  89. data/web/locales/fr.yml +78 -0
  90. data/web/locales/he.yml +79 -0
  91. data/web/locales/hi.yml +75 -0
  92. data/web/locales/it.yml +69 -0
  93. data/web/locales/ja.yml +83 -0
  94. data/web/locales/ko.yml +68 -0
  95. data/web/locales/lt.yml +83 -0
  96. data/web/locales/nb.yml +77 -0
  97. data/web/locales/nl.yml +68 -0
  98. data/web/locales/pl.yml +59 -0
  99. data/web/locales/pt-br.yml +68 -0
  100. data/web/locales/pt.yml +67 -0
  101. data/web/locales/ru.yml +78 -0
  102. data/web/locales/sv.yml +68 -0
  103. data/web/locales/ta.yml +75 -0
  104. data/web/locales/uk.yml +76 -0
  105. data/web/locales/ur.yml +80 -0
  106. data/web/locales/vi.yml +83 -0
  107. data/web/locales/zh-cn.yml +68 -0
  108. data/web/locales/zh-tw.yml +68 -0
  109. data/web/views/_footer.erb +20 -0
  110. data/web/views/_job_info.erb +89 -0
  111. data/web/views/_nav.erb +52 -0
  112. data/web/views/_paging.erb +23 -0
  113. data/web/views/_poll_link.erb +7 -0
  114. data/web/views/_status.erb +4 -0
  115. data/web/views/_summary.erb +40 -0
  116. data/web/views/busy.erb +101 -0
  117. data/web/views/dashboard.erb +75 -0
  118. data/web/views/dead.erb +34 -0
  119. data/web/views/layout.erb +41 -0
  120. data/web/views/morgue.erb +78 -0
  121. data/web/views/queue.erb +55 -0
  122. data/web/views/queues.erb +38 -0
  123. data/web/views/retries.erb +83 -0
  124. data/web/views/retry.erb +34 -0
  125. data/web/views/scheduled.erb +57 -0
  126. data/web/views/scheduled_job_info.erb +8 -0
  127. metadata +212 -0
@@ -0,0 +1,1718 @@
1
+ # Sidekiq Changes
2
+
3
+ [Sidekiq Changes](https://github.com/mperham/sidekiq/blob/master/Changes.md) | [Sidekiq Pro Changes](https://github.com/mperham/sidekiq/blob/master/Pro-Changes.md) | [Sidekiq Enterprise Changes](https://github.com/mperham/sidekiq/blob/master/Ent-Changes.md)
4
+
5
+ HEAD
6
+ ---------
7
+
8
+ - Web UI - Dark Mode fixes [#4543, natematykiewicz]
9
+ - Ensure `Rack::ContentLength` is loaded as middleware for correct Web UI responses [#4541]
10
+ - Avoid exception dumping SSL store in Redis connection logging [#4532]
11
+ - Better error messages in Sidekiq::Client [#4549]
12
+ - Remove rack-protection, reimplement CSRF protection [#4588]
13
+ - Require redis-rb 4.2 [#4591]
14
+ - Update to jquery 1.12.4 [#4593]
15
+ - Refactor internal fetch logic and API [#4602]
16
+
17
+ 6.0.7
18
+ ---------
19
+
20
+ - Refactor systemd integration to work better with custom binaries [#4511]
21
+ - Don't connect to Redis at process exit if not needed [#4502]
22
+ - Remove Redis connection naming [#4479]
23
+ - Fix Redis Sentinel password redaction [#4499]
24
+ - Add Vietnamese locale (vi) [#4528]
25
+
26
+ 6.0.6
27
+ ---------
28
+
29
+ - **Integrate with systemd's watchdog and notification features** [#4488]
30
+ Set `Type=notify` in [sidekiq.service](https://github.com/mperham/sidekiq/blob/4b8a8bd3ae42f6e48ae1fdaf95ed7d7af18ed8bb/examples/systemd/sidekiq.service#L30-L39). The integration works automatically.
31
+ - Use `setTimeout` rather than `setInterval` to avoid thundering herd [#4480]
32
+ - Fix edge case where a job can be pushed without a queue.
33
+ - Flush job stats at exit [#4498]
34
+ - Check RAILS_ENV before RACK_ENV [#4493]
35
+ - Add Lithuanian locale [#4476]
36
+
37
+ 6.0.5
38
+ ---------
39
+
40
+ - Fix broken Web UI response when using NewRelic and Rack 2.1.2+. [#4440]
41
+ - Update APIs to use `UNLINK`, not `DEL`. [#4449]
42
+ - Fix Ruby 2.7 warnings [#4412]
43
+ - Add support for `APP_ENV` [[95fa5d9]](https://github.com/mperham/sidekiq/commit/95fa5d90192148026e52ca2902f1b83c70858ce8)
44
+
45
+ 6.0.4
46
+ ---------
47
+
48
+ - Fix ActiveJob's `sidekiq_options` integration [#4404]
49
+ - Sidekiq Pro users will now see a Pause button next to each queue in
50
+ the Web UI, allowing them to pause queues manually [#4374, shayonj]
51
+ - Fix Sidekiq::Workers API unintentional change in 6.0.2 [#4387]
52
+
53
+
54
+ 6.0.3
55
+ ---------
56
+
57
+ - Fix `Sidekiq::Client.push_bulk` API which was erroneously putting
58
+ invalid `at` values in the job payloads [#4321]
59
+
60
+ 6.0.2
61
+ ---------
62
+
63
+ - Fix Sidekiq Enterprise's rolling restart functionality, broken by refactoring in 6.0.0. [#4334]
64
+ - More internal refactoring and performance tuning [fatkodima]
65
+
66
+ 6.0.1
67
+ ---------
68
+
69
+ - **Performance tuning**, Sidekiq should be 10-15% faster now [#4303, 4299,
70
+ 4269, fatkodima]
71
+ - **Dark Mode support in Web UI** (further design polish welcome!) [#4227, mperham,
72
+ fatkodima, silent-e]
73
+ - **Job-specific log levels**, allowing you to turn on debugging for
74
+ problematic workers. [fatkodima, #4287]
75
+ ```ruby
76
+ MyWorker.set(log_level: :debug).perform_async(...)
77
+ ```
78
+ - **Ad-hoc job tags**. You can tag your jobs with, e.g, subdomain, tenant, country,
79
+ locale, application, version, user/client, "alpha/beta/pro/ent", types of jobs,
80
+ teams/people responsible for jobs, additional metadata, etc.
81
+ Tags are shown on different pages with job listings. Sidekiq Pro users
82
+ can filter based on them [fatkodima, #4280]
83
+ ```ruby
84
+ class MyWorker
85
+ include Sidekiq::Worker
86
+ sidekiq_options tags: ['bank-ops', 'alpha']
87
+ ...
88
+ end
89
+ ```
90
+ - Fetch scheduled jobs in batches before pushing into specific queues.
91
+ This will decrease enqueueing time of scheduled jobs by a third. [fatkodima, #4273]
92
+ ```
93
+ ScheduledSet with 10,000 jobs
94
+ Before: 56.6 seconds
95
+ After: 39.2 seconds
96
+ ```
97
+ - Compress error backtraces before pushing into Redis, if you are
98
+ storing error backtraces, this will halve the size of your RetrySet
99
+ in Redis [fatkodima, #4272]
100
+ ```
101
+ RetrySet with 100,000 jobs
102
+ Before: 261 MB
103
+ After: 129 MB
104
+ ```
105
+ - Support display of ActiveJob 6.0 payloads in the Web UI [#4263]
106
+ - Add `SortedSet#scan` for pattern based scanning. For large sets this API will be **MUCH** faster
107
+ than standard iteration using each. [fatkodima, #4262]
108
+ ```ruby
109
+ Sidekiq::DeadSet.new.scan("UnreliableApi") do |job|
110
+ job.retry
111
+ end
112
+ ```
113
+ - Dramatically speed up SortedSet#find\_job(jid) by using Redis's ZSCAN
114
+ support, approx 10x faster. [fatkodima, #4259]
115
+ ```
116
+ zscan 0.179366 0.047727 0.227093 ( 1.161376)
117
+ enum 8.522311 0.419826 8.942137 ( 9.785079)
118
+ ```
119
+ - Respect rails' generators `test_framework` option and gracefully handle extra `worker` suffix on generator [fatkodima, #4256]
120
+ - Add ability to sort 'Enqueued' page on Web UI by position in the queue [fatkodima, #4248]
121
+ - Support `Client.push_bulk` with different delays [fatkodima, #4243]
122
+ ```ruby
123
+ Sidekiq::Client.push_bulk("class" => FooJob, "args" => [[1], [2]], "at" => [1.minute.from_now.to_f, 5.minutes.from_now.to_f])
124
+ ```
125
+ - Easier way to test enqueuing specific ActionMailer and ActiveRecord delayed jobs. Instead of manually
126
+ parsing embedded class, you can now test by fetching jobs for specific classes. [fatkodima, #4292]
127
+ ```ruby
128
+ assert_equal 1, Sidekiq::Extensions::DelayedMailer.jobs_for(FooMailer).size
129
+ ```
130
+ - Add `sidekiqmon` to gemspec executables [#4242]
131
+ - Gracefully handle `Sidekiq.logger = nil` [#4240]
132
+ - Inject Sidekiq::LogContext module if user-supplied logger does not include it [#4239]
133
+
134
+ 6.0
135
+ ---------
136
+
137
+ This release has major breaking changes. Read and test carefully in production.
138
+
139
+ - With Rails 6.0.1+, ActiveJobs can now use `sidekiq_options` directly to configure Sidekiq
140
+ features/internals like the retry subsystem. [#4213, pirj]
141
+ ```ruby
142
+ class MyJob < ActiveJob::Base
143
+ queue_as :myqueue
144
+ sidekiq_options retry: 10, backtrace: 20
145
+ def perform(...)
146
+ end
147
+ end
148
+ ```
149
+ - Logging has been redesigned to allow for pluggable log formatters:
150
+ ```ruby
151
+ Sidekiq.configure_server do |config|
152
+ config.log_formatter = Sidekiq::Logger::Formatters::JSON.new
153
+ end
154
+ ```
155
+ See the [Logging wiki page](https://github.com/mperham/sidekiq/wiki/Logging) for more details.
156
+ - **BREAKING CHANGE** Validate proper usage of the `REDIS_PROVIDER`
157
+ variable. This variable is meant to hold the name of the environment
158
+ variable which contains your Redis URL, so that you can switch Redis
159
+ providers quickly and easily with a single variable change. It is not
160
+ meant to hold the actual Redis URL itself. If you want to manually set
161
+ the Redis URL (not recommended as it implies you have no failover),
162
+ then you may set `REDIS_URL` directly. [#3969]
163
+ - **BREAKING CHANGE** Increase default shutdown timeout from 8 seconds
164
+ to 25 seconds. Both Heroku and ECS now use 30 second shutdown timeout
165
+ by default and we want Sidekiq to take advantage of this time. If you
166
+ have deployment scripts which depend on the old default timeout, use `-t 8` to
167
+ get the old behavior. [#3968]
168
+ - **BREAKING CHANGE** Remove the daemonization, logfile and pidfile
169
+ arguments to Sidekiq. Use a proper process supervisor (e.g. systemd or
170
+ foreman) to manage Sidekiq. See the Deployment wiki page for links to
171
+ more resources.
172
+ - Integrate the StandardRB code formatter to ensure consistent code
173
+ styling. [#4114, gearnode]
174
+
175
+ 5.2.9
176
+ ---------
177
+
178
+ - Release Rack lock due to a cascade of CVEs. [#4566]
179
+ Pro-tip: don't lock Rack.
180
+
181
+ 5.2.8
182
+ ---------
183
+
184
+ - Lock to Rack 2.0.x to prevent future incompatibilities
185
+ - Fix invalid reference in `sidekiqctl`
186
+
187
+ 5.2.7
188
+ ---------
189
+
190
+ - Fix stale `enqueued_at` when retrying [#4149]
191
+ - Move build to [Circle CI](https://circleci.com/gh/mperham/sidekiq) [#4120]
192
+
193
+ 5.2.6
194
+ ---------
195
+
196
+ - Fix edge case where a job failure during Redis outage could result in a lost job [#4141]
197
+ - Better handling of malformed job arguments in payload [#4095]
198
+ - Restore bootstap's dropdown css component [#4099, urkle]
199
+ - Display human-friendly time diff for longer queue latencies [#4111, interlinked]
200
+ - Allow `Sidekiq::Worker#set` to be chained
201
+
202
+ 5.2.5
203
+ ---------
204
+
205
+ - Fix default usage of `config/sidekiq.yml` [#4077, Tensho]
206
+
207
+ 5.2.4
208
+ ---------
209
+
210
+ - Add warnings for various deprecations and changes coming in Sidekiq 6.0.
211
+ See the 6-0 branch. [#4056]
212
+ - Various improvements to the Sidekiq test suite and coverage [#4026, #4039, Tensho]
213
+
214
+ 5.2.3
215
+ ---------
216
+
217
+ - Warning message on invalid REDIS\_PROVIDER [#3970]
218
+ - Add `sidekiqctl status` command [#4003, dzunk]
219
+ - Update elapsed time calculatons to use monotonic clock [#3999]
220
+ - Fix a few issues with mobile Web UI styling [#3973, navied]
221
+ - Jobs with `retry: false` now go through the global `death_handlers`,
222
+ meaning you can take action on failed ephemeral jobs. [#3980, Benjamin-Dobell]
223
+ - Fix race condition in defining Workers. [#3997, mattbooks]
224
+
225
+ 5.2.2
226
+ ---------
227
+
228
+ - Raise error for duplicate queue names in config to avoid unexpected fetch algorithm change [#3911]
229
+ - Fix concurrency bug on JRuby [#3958, mattbooks]
230
+ - Add "Kill All" button to the retries page [#3938]
231
+
232
+ 5.2.1
233
+ -----------
234
+
235
+ - Fix concurrent modification error during heartbeat [#3921]
236
+
237
+ 5.2.0
238
+ -----------
239
+
240
+ - **Decrease default concurrency from 25 to 10** [#3892]
241
+ - Verify connection pool sizing upon startup [#3917]
242
+ - Smoother scheduling for large Sidekiq clusters [#3889]
243
+ - Switch Sidekiq::Testing impl from alias\_method to Module#prepend, for resiliency [#3852]
244
+ - Update Sidekiq APIs to use SCAN for scalability [#3848, ffiller]
245
+ - Remove concurrent-ruby gem dependency [#3830]
246
+ - Optimize Web UI's bootstrap.css [#3914]
247
+
248
+ 5.1.3
249
+ -----------
250
+
251
+ - Fix version comparison so Ruby 2.2.10 works. [#3808, nateberkopec]
252
+
253
+ 5.1.2
254
+ -----------
255
+
256
+ - Add link to docs in Web UI footer
257
+ - Fix crash on Ctrl-C in Windows [#3775, Bernica]
258
+ - Remove `freeze` calls on String constants. This is superfluous with Ruby
259
+ 2.3+ and `frozen_string_literal: true`. [#3759]
260
+ - Fix use of AR middleware outside of Rails [#3787]
261
+ - Sidekiq::Worker `sidekiq_retry_in` block can now return nil or 0 to use
262
+ the default backoff delay [#3796, dsalahutdinov]
263
+
264
+ 5.1.1
265
+ -----------
266
+
267
+ - Fix Web UI incompatibility with Redis 3.x gem [#3749]
268
+
269
+ 5.1.0
270
+ -----------
271
+
272
+ - **NEW** Global death handlers - called when your job exhausts all
273
+ retries and dies. Now you can take action when a job fails permanently. [#3721]
274
+ - **NEW** Enable ActiveRecord query cache within jobs by default [#3718, sobrinho]
275
+ This will prevent duplicate SELECTS; cache is cleared upon any UPDATE/INSERT/DELETE.
276
+ See the issue for how to bypass the cache or disable it completely.
277
+ - Scheduler timing is now more accurate, 15 -> 5 seconds [#3734]
278
+ - Exceptions during the :startup event will now kill the process [#3717]
279
+ - Make `Sidekiq::Client.via` reentrant [#3715]
280
+ - Fix use of Sidekiq logger outside of the server process [#3714]
281
+ - Tweak `constantize` to better match Rails class lookup. [#3701, caffeinated-tech]
282
+
283
+ 5.0.5
284
+ -----------
285
+
286
+ - Update gemspec to allow newer versions of the Redis gem [#3617]
287
+ - Refactor Worker.set so it can be memoized [#3602]
288
+ - Fix display of Redis URL in web footer, broken in 5.0.3 [#3560]
289
+ - Update `Sidekiq::Job#display_args` to avoid mutation [#3621]
290
+
291
+ 5.0.4
292
+ -----------
293
+
294
+ - Fix "slow startup" performance regression from 5.0.2. [#3525]
295
+ - Allow users to disable ID generation since some redis providers disable the CLIENT command. [#3521]
296
+
297
+ 5.0.3
298
+ -----------
299
+
300
+ - Fix overriding `class_attribute` core extension from ActiveSupport with Sidekiq one [PikachuEXE, #3499]
301
+ - Allow job logger to be overridden [AlfonsoUceda, #3502]
302
+ - Set a default Redis client identifier for debugging [#3516]
303
+ - Fix "Uninitialized constant" errors on startup with the delayed extensions [#3509]
304
+
305
+ 5.0.2
306
+ -----------
307
+
308
+ - fix broken release, thanks @nateberkopec
309
+
310
+ 5.0.1
311
+ -----------
312
+
313
+ - Fix incorrect server identity when daemonizing [jwilm, #3496]
314
+ - Work around error running Web UI against Redis Cluster [#3492]
315
+ - Remove core extensions, Sidekiq is now monkeypatch-free! [#3474]
316
+ - Reimplement Web UI's HTTP\_ACCEPT\_LANGUAGE parsing because the spec is utterly
317
+ incomprehensible for various edge cases. [johanlunds, natematykiewicz, #3449]
318
+ - Update `class_attribute` core extension to avoid warnings
319
+ - Expose `job_hash_context` from `Sidekiq::Logging` to support log customization
320
+
321
+ 5.0.0
322
+ -----------
323
+
324
+ - **BREAKING CHANGE** Job dispatch was refactored for safer integration with
325
+ Rails 5. The **Logging** and **RetryJobs** server middleware were removed and
326
+ functionality integrated directly into Sidekiq::Processor. These aren't
327
+ commonly used public APIs so this shouldn't impact most users.
328
+ ```
329
+ Sidekiq::Middleware::Server::RetryJobs -> Sidekiq::JobRetry
330
+ Sidekiq::Middleware::Server::Logging -> Sidekiq::JobLogger
331
+ ```
332
+ - Quieting Sidekiq is now done via the TSTP signal, the USR1 signal is deprecated.
333
+ - The `delay` extension APIs are no longer available by default, you
334
+ must opt into them.
335
+ - The Web UI is now BiDi and can render RTL languages like Arabic, Farsi and Hebrew.
336
+ - Rails 3.2 and Ruby 2.0 and 2.1 are no longer supported.
337
+ - The `SomeWorker.set(options)` API was re-written to avoid thread-local state. [#2152]
338
+ - Sidekiq Enterprise's encrypted jobs now display "[encrypted data]" in the Web UI instead
339
+ of random hex bytes.
340
+ - Please see the [5.0 Upgrade notes](5.0-Upgrade.md) for more detail.
341
+
342
+ 4.2.10
343
+ -----------
344
+
345
+ - Scheduled jobs can now be moved directly to the Dead queue via API [#3390]
346
+ - Fix edge case leading to job duplication when using Sidekiq Pro's
347
+ reliability feature [#3388]
348
+ - Fix error class name display on retry page [#3348]
349
+ - More robust latency calculation [#3340]
350
+
351
+ 4.2.9
352
+ -----------
353
+
354
+ - Rollback [#3303] which broke Heroku Redis users [#3311]
355
+ - Add support for TSTP signal, for Sidekiq 5.0 forward compatibility. [#3302]
356
+
357
+ 4.2.8
358
+ -----------
359
+
360
+ - Fix rare edge case with Redis driver that can create duplicate jobs [#3303]
361
+ - Fix Rails 5 loading issue [#3275]
362
+ - Restore missing tooltips to timestamps in Web UI [#3310]
363
+ - Work on **Sidekiq 5.0** is now active! [#3301]
364
+
365
+ 4.2.7
366
+ -----------
367
+
368
+ - Add new integration testing to verify code loading and job execution
369
+ in development and production modes with Rails 4 and 5 [#3241]
370
+ - Fix delayed extensions in development mode [#3227, DarthSim]
371
+ - Use Worker's `retry` default if job payload does not have a retry
372
+ attribute [#3234, mlarraz]
373
+
374
+ 4.2.6
375
+ -----------
376
+
377
+ - Run Rails Executor when in production [#3221, eugeneius]
378
+
379
+ 4.2.5
380
+ -----------
381
+
382
+ - Re-enable eager loading of all code when running non-development Rails 5. [#3203]
383
+ - Better root URL handling for zany web servers [#3207]
384
+
385
+ 4.2.4
386
+ -----------
387
+
388
+ - Log errors coming from the Rails 5 reloader. [#3212, eugeneius]
389
+ - Clone job data so middleware changes don't appear in Busy tab
390
+
391
+ 4.2.3
392
+ -----------
393
+
394
+ - Disable use of Rails 5's Reloader API in non-development modes, it has proven
395
+ to be unstable under load [#3154]
396
+ - Allow disabling of Sidekiq::Web's cookie session to handle the
397
+ case where the app provides a session already [#3180, inkstak]
398
+ ```ruby
399
+ Sidekiq::Web.set :sessions, false
400
+ ```
401
+ - Fix Web UI sharding support broken in 4.2.2. [#3169]
402
+ - Fix timestamps not updating during UI polling [#3193, shaneog]
403
+ - Relax rack-protection version to >= 1.5.0
404
+ - Provide consistent interface to exception handlers, changing the structure of the context hash. [#3161]
405
+
406
+ 4.2.2
407
+ -----------
408
+
409
+ - Fix ever-increasing cookie size with nginx [#3146, cconstantine]
410
+ - Fix so Web UI works without trailing slash [#3158, timdorr]
411
+
412
+ 4.2.1
413
+ -----------
414
+
415
+ - Ensure browser does not cache JSON/AJAX responses. [#3136]
416
+ - Support old Sinatra syntax for setting config [#3139]
417
+
418
+ 4.2.0
419
+ -----------
420
+
421
+ - Enable development-mode code reloading. **With Rails 5.0+, you don't need
422
+ to restart Sidekiq to pick up your Sidekiq::Worker changes anymore!** [#2457]
423
+ - **Remove Sinatra dependency**. Sidekiq's Web UI now uses Rack directly.
424
+ Thank you to Sidekiq's newest committer, **badosu**, for writing the code
425
+ and doing a lot of testing to ensure compatibility with many different
426
+ 3rd party plugins. If your Web UI works with 4.1.4 but fails with
427
+ 4.2.0, please open an issue. [#3075]
428
+ - Allow tuning of concurrency with the `RAILS_MAX_THREADS` env var. [#2985]
429
+ This is the same var used by Puma so you can tune all of your systems
430
+ the same way:
431
+ ```sh
432
+ web: RAILS_MAX_THREADS=5 bundle exec puma ...
433
+ worker: RAILS_MAX_THREADS=10 bundle exec sidekiq ...
434
+ ```
435
+ Using `-c` or `config/sidekiq.yml` overrides this setting. I recommend
436
+ adjusting your `config/database.yml` to use it too so connections are
437
+ auto-scaled:
438
+ ```yaml
439
+ pool: <%= ENV['RAILS_MAX_THREADS'] || 5 %>
440
+ ```
441
+
442
+ 4.1.4
443
+ -----------
444
+
445
+ - Unlock Sinatra so a Rails 5.0 compatible version may be used [#3048]
446
+ - Fix race condition on startup with JRuby [#3043]
447
+
448
+
449
+ 4.1.3
450
+ -----------
451
+
452
+ - Please note the Redis 3.3.0 gem has a [memory leak](https://github.com/redis/redis-rb/issues/612),
453
+ Redis 3.2.2 is recommended until that issue is fixed.
454
+ - Sinatra 1.4.x is now a required dependency, avoiding cryptic errors
455
+ and old bugs due to people not upgrading Sinatra for years. [#3042]
456
+ - Fixed race condition in heartbeat which could rarely lead to lingering
457
+ processes on the Busy tab. [#2982]
458
+ ```ruby
459
+ # To clean up lingering processes, modify this as necessary to connect to your Redis.
460
+ # After 60 seconds, lingering processes should disappear from the Busy page.
461
+
462
+ require 'redis'
463
+ r = Redis.new(url: "redis://localhost:6379/0")
464
+ # uncomment if you need a namespace
465
+ #require 'redis-namespace'
466
+ #r = Redis::Namespace.new("foo", r)
467
+ r.smembers("processes").each do |pro|
468
+ r.expire(pro, 60)
469
+ r.expire("#{pro}:workers", 60)
470
+ end
471
+ ```
472
+
473
+
474
+ 4.1.2
475
+ -----------
476
+
477
+ - Fix Redis data leak with worker data when a busy Sidekiq process
478
+ crashes. You can find and expire leaked data in Redis with this
479
+ script:
480
+ ```bash
481
+ $ redis-cli keys "*:workers" | while read LINE ; do TTL=`redis-cli expire "$LINE" 60`; echo "$LINE"; done;
482
+ ```
483
+ Please note that `keys` can be dangerous to run on a large, busy Redis. Caveat runner.
484
+ - Freeze all string literals with Ruby 2.3. [#2741]
485
+ - Client middleware can now stop bulk job push. [#2887]
486
+
487
+ 4.1.1
488
+ -----------
489
+
490
+ - Much better behavior when Redis disappears and comes back. [#2866]
491
+ - Update FR locale [dbachet]
492
+ - Don't fill logfile in case of Redis downtime [#2860]
493
+ - Allow definition of a global retries_exhausted handler. [#2807]
494
+ ```ruby
495
+ Sidekiq.configure_server do |config|
496
+ config.default_retries_exhausted = -> (job, ex) do
497
+ Sidekiq.logger.info "#{job['class']} job is now dead"
498
+ end
499
+ end
500
+ ```
501
+
502
+ 4.1.0
503
+ -----------
504
+
505
+ - Tag quiet processes in the Web UI [#2757, jcarlson]
506
+ - Pass last exception to sidekiq\_retries\_exhausted block [#2787, Nowaker]
507
+ ```ruby
508
+ class MyWorker
509
+ include Sidekiq::Worker
510
+ sidekiq_retries_exhausted do |job, exception|
511
+ end
512
+ end
513
+ ```
514
+ - Add native support for ActiveJob's `set(options)` method allowing
515
+ you to override worker options dynamically. This should make it
516
+ even easier to switch between ActiveJob and Sidekiq's native APIs [#2780]
517
+ ```ruby
518
+ class MyWorker
519
+ include Sidekiq::Worker
520
+ sidekiq_options queue: 'default', retry: true
521
+
522
+ def perform(*args)
523
+ # do something
524
+ end
525
+ end
526
+
527
+ MyWorker.set(queue: 'high', retry: false).perform_async(1)
528
+ ```
529
+
530
+ 4.0.2
531
+ -----------
532
+
533
+ - Better Japanese translations
534
+ - Remove `json` gem dependency from gemspec. [#2743]
535
+ - There's a new testing API based off the `Sidekiq::Queues` namespace. All
536
+ assertions made against the Worker class still work as expected.
537
+ [#2676, brandonhilkert]
538
+ ```ruby
539
+ assert_equal 0, Sidekiq::Queues["default"].size
540
+ HardWorker.perform_async("log")
541
+ assert_equal 1, Sidekiq::Queues["default"].size
542
+ assert_equal "log", Sidekiq::Queues["default"].first['args'][0]
543
+ Sidekiq::Queues.clear_all
544
+ ```
545
+
546
+ 4.0.1
547
+ -----------
548
+
549
+ - Yank new queue-based testing API [#2663]
550
+ - Fix invalid constant reference in heartbeat
551
+
552
+ 4.0.0
553
+ -----------
554
+
555
+ - Sidekiq's internals have been completely overhauled for performance
556
+ and to remove dependencies. This has resulted in major speedups, as
557
+ [detailed on my blog](http://www.mikeperham.com/2015/10/14/optimizing-sidekiq/).
558
+ - See the [4.0 upgrade notes](4.0-Upgrade.md) for more detail.
559
+
560
+ 3.5.4
561
+ -----------
562
+
563
+ - Ensure exception message is a string [#2707]
564
+ - Revert racy Process.kill usage in sidekiqctl
565
+
566
+ 3.5.3
567
+ -----------
568
+
569
+ - Adjust shutdown event to run in parallel with the rest of system shutdown. [#2635]
570
+
571
+ 3.5.2
572
+ -----------
573
+
574
+ - **Sidekiq 3 is now in maintenance mode**, only major bugs will be fixed.
575
+ - The exception triggering a retry is now passed into `sidekiq_retry_in`,
576
+ allowing you to retry more frequently for certain types of errors.
577
+ [#2619, kreynolds]
578
+ ```ruby
579
+ sidekiq_retry_in do |count, ex|
580
+ case ex
581
+ when RuntimeError
582
+ 5 * count
583
+ else
584
+ 10 * count
585
+ end
586
+ end
587
+ ```
588
+
589
+ 3.5.1
590
+ -----------
591
+
592
+ - **FIX MEMORY LEAK** Under rare conditions, threads may leak [#2598, gazay]
593
+ - Add Ukrainian locale [#2561, elrakita]
594
+ - Disconnect and retry Redis operations if we see a READONLY error [#2550]
595
+ - Add server middleware testing harness; see [wiki](https://github.com/mperham/sidekiq/wiki/Testing#testing-server-middleware) [#2534, ryansch]
596
+
597
+ 3.5.0
598
+ -----------
599
+
600
+ - Polished new banner! [#2522, firedev]
601
+ - Upgrade to Celluloid 0.17. [#2420, digitalextremist]
602
+ - Activate sessions in Sinatra for CSRF protection, requires Rails
603
+ monkeypatch due to rails/rails#15843. [#2460, jc00ke]
604
+
605
+ 3.4.2
606
+ -----------
607
+
608
+ - Don't allow `Sidekiq::Worker` in ActiveJob::Base classes. [#2424]
609
+ - Safer display of job data in Web UI [#2405]
610
+ - Fix CSRF vulnerability in Web UI, thanks to Egor Homakov for
611
+ reporting. [#2422] If you are running the Web UI as a standalone Rack app,
612
+ ensure you have a [session middleware
613
+ configured](https://github.com/mperham/sidekiq/wiki/Monitoring#standalone):
614
+ ```ruby
615
+ use Rack::Session::Cookie, :secret => "some unique secret string here"
616
+ ```
617
+
618
+ 3.4.1
619
+ -----------
620
+
621
+ - Lock to Celluloid 0.16
622
+
623
+
624
+ 3.4.0
625
+ -----------
626
+
627
+ - Set a `created_at` attribute when jobs are created, set `enqueued_at` only
628
+ when they go into a queue. Fixes invalid latency calculations with scheduled jobs.
629
+ [#2373, mrsimo]
630
+ - Don't log timestamp on Heroku [#2343]
631
+ - Run `shutdown` event handlers in reverse order of definition [#2374]
632
+ - Rename and rework `poll_interval` to be simpler, more predictable [#2317, cainlevy]
633
+ The new setting is `average_scheduled_poll_interval`. To configure
634
+ Sidekiq to look for scheduled jobs every 5 seconds, just set it to 5.
635
+ ```ruby
636
+ Sidekiq.configure_server do |config|
637
+ config.average_scheduled_poll_interval = 5
638
+ end
639
+ ```
640
+
641
+ 3.3.4
642
+ -----------
643
+
644
+ - **Improved ActiveJob integration** - Web UI now shows ActiveJobs in a
645
+ nicer format and job logging shows the actual class name, requires
646
+ Rails 4.2.2+ [#2248, #2259]
647
+ - Add Sidekiq::Process#dump\_threads API to trigger TTIN output [#2247]
648
+ - Web UI polling now uses Ajax to avoid page reload [#2266, davydovanton]
649
+ - Several Web UI styling improvements [davydovanton]
650
+ - Add Tamil, Hindi translations for Web UI [ferdinandrosario, tejasbubane]
651
+ - Fix Web UI to work with country-specific locales [#2243]
652
+ - Handle circular error causes [#2285, eugenk]
653
+
654
+ 3.3.3
655
+ -----------
656
+
657
+ - Fix crash on exit when Redis is down [#2235]
658
+ - Fix duplicate logging on startup
659
+ - Undeprecate delay extension for ActionMailer 4.2+ . [#2186]
660
+
661
+ 3.3.2
662
+ -----------
663
+
664
+ - Add Sidekiq::Stats#queues back
665
+ - Allows configuration of dead job set size and timeout [#2173, jonhyman]
666
+ - Refactor scheduler enqueuing so Sidekiq Pro can override it. [#2159]
667
+
668
+ 3.3.1
669
+ -----------
670
+
671
+ - Dumb down ActionMailer integration so it tries to deliver if possible [#2149]
672
+ - Stringify Sidekiq.default\_worker\_options's keys [#2126]
673
+ - Add random integer to process identity [#2113, michaeldiscala]
674
+ - Log Sidekiq Pro's Batch ID if available [#2076]
675
+ - Refactor Processor Redis usage to avoid redis/redis-rb#490 [#2094]
676
+ - Move /dashboard/stats to /stats. Add /stats/queues. [moserke, #2099]
677
+ - Add processes count to /stats [ismaelga, #2141]
678
+ - Greatly improve speed of Sidekiq::Stats [ismaelga, #2142]
679
+ - Add better usage text for `sidekiqctl`.
680
+ - `Sidekiq::Logging.with_context` is now a stack so you can set your
681
+ own job context for logging purposes [grosser, #2110]
682
+ - Remove usage of Google Fonts in Web UI so it loads in China [#2144]
683
+
684
+ 3.3.0
685
+ -----------
686
+
687
+ - Upgrade to Celluloid 0.16 [#2056]
688
+ - Fix typo for generator test file name [dlackty, #2016]
689
+ - Add Sidekiq::Middleware::Chain#prepend [seuros, #2029]
690
+
691
+ 3.2.6
692
+ -----------
693
+
694
+ - Deprecate delay extension for ActionMailer 4.2+ . [seuros, #1933]
695
+ - Poll interval tuning now accounts for dead processes [epchris, #1984]
696
+ - Add non-production environment to Web UI page titles [JacobEvelyn, #2004]
697
+
698
+ 3.2.5
699
+ -----------
700
+
701
+ - Lock Celluloid to 0.15.2 due to bugs in 0.16.0. This prevents the
702
+ "hang on shutdown" problem with Celluloid 0.16.0.
703
+
704
+ 3.2.4
705
+ -----------
706
+
707
+ - Fix issue preventing ActionMailer sends working in some cases with
708
+ Rails 4. [pbhogan, #1923]
709
+
710
+ 3.2.3
711
+ -----------
712
+
713
+ - Clean invalid bytes from error message before converting to JSON (requires Ruby 2.1+) [#1705]
714
+ - Add queues list for each process to the Busy page. [davetoxa, #1897]
715
+ - Fix for crash caused by empty config file. [jordan0day, #1901]
716
+ - Add Rails Worker generator, `rails g sidekiq:worker User` will create `app/workers/user_worker.rb`. [seuros, #1909]
717
+ - Fix Web UI rendering with huge job arguments [jhass, #1918]
718
+ - Minor refactoring of Sidekiq::Client internals, for Sidekiq Pro. [#1919]
719
+
720
+ 3.2.2
721
+ -----------
722
+
723
+ - **This version of Sidekiq will no longer start on Ruby 1.9.** Sidekiq
724
+ 3 does not support MRI 1.9 but we've allowed it to run before now.
725
+ - Fix issue which could cause Sidekiq workers to disappear from the Busy
726
+ tab while still being active [#1884]
727
+ - Add "Back to App" button in Web UI. You can set the button link via
728
+ `Sidekiq::Web.app_url = 'http://www.mysite.com'` [#1875, seuros]
729
+ - Add process tag (`-g tag`) to the Busy page so you can differentiate processes at a glance. [seuros, #1878]
730
+ - Add "Kill" button to move retries directly to the DJQ so they don't retry. [seuros, #1867]
731
+
732
+ 3.2.1
733
+ -----------
734
+
735
+ - Revert eager loading change for Rails 3.x apps, as it broke a few edge
736
+ cases.
737
+
738
+ 3.2.0
739
+ -----------
740
+
741
+ - **Fix issue which caused duplicate job execution in Rails 3.x**
742
+ This issue is caused by [improper exception handling in ActiveRecord](https://github.com/rails/rails/blob/3-2-stable/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb#L281) which changes Sidekiq's Shutdown exception into a database
743
+ error, making Sidekiq think the job needs to be retried. **The fix requires Ruby 2.1**. [#1805]
744
+ - Update how Sidekiq eager loads Rails application code [#1791, jonleighton]
745
+ - Change logging timestamp to show milliseconds.
746
+ - Reverse sorting of Dead tab so newer jobs are listed first [#1802]
747
+
748
+ 3.1.4
749
+ -----------
750
+
751
+ - Happy π release!
752
+ - Self-tuning Scheduler polling, we use heartbeat info to better tune poll\_interval [#1630]
753
+ - Remove all table column width rules, hopefully get better column formatting [#1747]
754
+ - Handle edge case where YAML can't be decoded in dev mode [#1761]
755
+ - Fix lingering jobs in Busy page on Heroku [#1764]
756
+
757
+ 3.1.3
758
+ -----------
759
+
760
+ - Use ENV['DYNO'] on Heroku for hostname display, rather than an ugly UUID. [#1742]
761
+ - Show per-process labels on the Busy page, for feature tagging [#1673]
762
+
763
+
764
+ 3.1.2
765
+ -----------
766
+
767
+ - Suitably chastised, @mperham reverts the Bundler change.
768
+
769
+
770
+ 3.1.1
771
+ -----------
772
+
773
+ - Sidekiq::CLI now runs `Bundler.require(:default, environment)` to boot all gems
774
+ before loading any app code.
775
+ - Sort queues by name in Web UI [#1734]
776
+
777
+
778
+ 3.1.0
779
+ -----------
780
+
781
+ - New **remote control** feature: you can remotely trigger Sidekiq to quiet
782
+ or terminate via API, without signals. This is most useful on JRuby
783
+ or Heroku which does not support the USR1 'quiet' signal. Now you can
784
+ run a rake task like this at the start of your deploy to quiet your
785
+ set of Sidekiq processes. [#1703]
786
+ ```ruby
787
+ namespace :sidekiq do
788
+ task :quiet => :environment do
789
+ Sidekiq::ProcessSet.new.each(&:quiet!)
790
+ end
791
+ end
792
+ ```
793
+ - The Web UI can use the API to quiet or stop all processes via the Busy page.
794
+ - The Web UI understands and hides the `Sidekiq::Extensions::Delay*`
795
+ classes, instead showing `Class.method` as the Job. [#1718]
796
+ - Polish the Dashboard graphs a bit, update Rickshaw [brandonhilkert, #1725]
797
+ - The poll interval is now configurable in the Web UI [madebydna, #1713]
798
+ - Delay extensions can be removed so they don't conflict with
799
+ DelayedJob: put `Sidekiq.remove_delay!` in your initializer. [devaroop, #1674]
800
+
801
+
802
+ 3.0.2
803
+ -----------
804
+
805
+ - Revert gemfile requirement of Ruby 2.0. JRuby 1.7 calls itself Ruby
806
+ 1.9.3 and broke with this requirement.
807
+
808
+ 3.0.1
809
+ -----------
810
+
811
+ - Revert pidfile behavior from 2.17.5: Sidekiq will no longer remove its own pidfile
812
+ as this is a race condition when restarting. [#1470, #1677]
813
+ - Show warning on the Queues page if a queue is paused [#1672]
814
+ - Only activate the ActiveRecord middleware if ActiveRecord::Base is defined on boot. [#1666]
815
+ - Add ability to disable jobs going to the DJQ with the `dead` option.
816
+ ```ruby
817
+ sidekiq_options :dead => false, :retry => 5
818
+ ```
819
+ - Minor fixes
820
+
821
+
822
+ 3.0.0
823
+ -----------
824
+
825
+ Please see [3.0-Upgrade.md](3.0-Upgrade.md) for more comprehensive upgrade notes.
826
+
827
+ - **Dead Job Queue** - jobs which run out of retries are now moved to a dead
828
+ job queue. These jobs must be retried manually or they will expire
829
+ after 6 months or 10,000 jobs. The Web UI contains a "Dead" tab
830
+ exposing these jobs. Use `sidekiq_options :retry => false` if you
831
+ don't wish jobs to be retried or put in the DJQ. Use
832
+ `sidekiq_options :retry => 0` if you don't want jobs to retry but go
833
+ straight to the DJQ.
834
+ - **Process Lifecycle Events** - you can now register blocks to run at
835
+ certain points during the Sidekiq process lifecycle: startup, quiet and
836
+ shutdown.
837
+ ```ruby
838
+ Sidekiq.configure_server do |config|
839
+ config.on(:startup) do
840
+ # do something
841
+ end
842
+ end
843
+ ```
844
+ - **Global Error Handlers** - blocks of code which handle errors that
845
+ occur anywhere within Sidekiq, not just within middleware.
846
+ ```ruby
847
+ Sidekiq.configure_server do |config|
848
+ config.error_handlers << proc {|ex,ctx| ... }
849
+ end
850
+ ```
851
+ - **Process Heartbeat** - each Sidekiq process will ping Redis every 5
852
+ seconds to give a summary of the Sidekiq population at work.
853
+ - The Workers tab is now renamed to Busy and contains a list of live
854
+ Sidekiq processes and jobs in progress based on the heartbeat.
855
+ - **Shardable Client** - Sidekiq::Client instances can use a custom
856
+ Redis connection pool, allowing very large Sidekiq installations to scale by
857
+ sharding: sending different jobs to different Redis instances.
858
+ ```ruby
859
+ client = Sidekiq::Client.new(ConnectionPool.new { Redis.new })
860
+ client.push(...)
861
+ ```
862
+ ```ruby
863
+ Sidekiq::Client.via(ConnectionPool.new { Redis.new }) do
864
+ FooWorker.perform_async
865
+ BarWorker.perform_async
866
+ end
867
+ ```
868
+ **Sharding support does require a breaking change to client-side
869
+ middleware, see 3.0-Upgrade.md.**
870
+ - New Chinese, Greek, Swedish and Czech translations for the Web UI.
871
+ - Updated most languages translations for the new UI features.
872
+ - **Remove official Capistrano integration** - this integration has been
873
+ moved into the [capistrano-sidekiq](https://github.com/seuros/capistrano-sidekiq) gem.
874
+ - **Remove official support for MRI 1.9** - Things still might work but
875
+ I no longer actively test on it.
876
+ - **Remove built-in support for Redis-to-Go**.
877
+ Heroku users: `heroku config:set REDIS_PROVIDER=REDISTOGO_URL`
878
+ - **Remove built-in error integration for Airbrake, Honeybadger, ExceptionNotifier and Exceptional**.
879
+ Each error gem should provide its own Sidekiq integration. Update your error gem to the latest
880
+ version to pick up Sidekiq support.
881
+ - Upgrade to connection\_pool 2.0 which now creates connections lazily.
882
+ - Remove deprecated Sidekiq::Client.registered\_\* APIs
883
+ - Remove deprecated support for the old Sidekiq::Worker#retries\_exhausted method.
884
+ - Removed 'sidekiq/yaml\_patch', this was never documented or recommended.
885
+ - Removed --profile option, #1592
886
+ - Remove usage of the term 'Worker' in the UI for clarity. Users would call both threads and
887
+ processes 'workers'. Instead, use "Thread", "Process" or "Job".
888
+
889
+ 2.17.7
890
+ -----------
891
+
892
+ - Auto-prune jobs older than one hour from the Workers page [#1508]
893
+ - Add Sidekiq::Workers#prune which can perform the auto-pruning.
894
+ - Fix issue where a job could be lost when an exception occurs updating
895
+ Redis stats before the job executes [#1511]
896
+
897
+ 2.17.6
898
+ -----------
899
+
900
+ - Fix capistrano integration due to missing pidfile. [#1490]
901
+
902
+ 2.17.5
903
+ -----------
904
+
905
+ - Automatically use the config file found at `config/sidekiq.yml`, if not passed `-C`. [#1481]
906
+ - Store 'retried\_at' and 'failed\_at' timestamps as Floats, not Strings. [#1473]
907
+ - A `USR2` signal will now reopen _all_ logs, using IO#reopen. Thus, instead of creating a new Logger object,
908
+ Sidekiq will now just update the existing Logger's file descriptor [#1163].
909
+ - Remove pidfile when shutting down if started with `-P` [#1470]
910
+
911
+ 2.17.4
912
+ -----------
913
+
914
+ - Fix JID support in inline testing, #1454
915
+ - Polish worker arguments display in UI, #1453
916
+ - Marshal arguments fully to avoid worker mutation, #1452
917
+ - Support reverse paging sorted sets, #1098
918
+
919
+
920
+ 2.17.3
921
+ -----------
922
+
923
+ - Synchronously terminates the poller and fetcher to fix a race condition in bulk requeue during shutdown [#1406]
924
+
925
+ 2.17.2
926
+ -----------
927
+
928
+ - Fix bug where strictly prioritized queues might be processed out of
929
+ order [#1408]. A side effect of this change is that it breaks a queue
930
+ declaration syntax that worked, although only because of a bug—it was
931
+ never intended to work and never supported. If you were declaring your
932
+ queues as a comma-separated list, e.g. `sidekiq -q critical,default,low`,
933
+ you must now use the `-q` flag before each queue, e.g.
934
+ `sidekiq -q critical -q default -q low`.
935
+
936
+ 2.17.1
937
+ -----------
938
+
939
+ - Expose `delay` extension as `sidekiq_delay` also. This allows you to
940
+ run Delayed::Job and Sidekiq in the same process, selectively porting
941
+ `delay` calls to `sidekiq_delay`. You just need to ensure that
942
+ Sidekiq is required **before** Delayed::Job in your Gemfile. [#1393]
943
+ - Bump redis client required version to 3.0.6
944
+ - Minor CSS fixes for Web UI
945
+
946
+ 2.17.0
947
+ -----------
948
+
949
+ - Change `Sidekiq::Client#push_bulk` to return an array of pushed `jid`s. [#1315, barelyknown]
950
+ - Web UI refactoring to use more API internally (yummy dogfood!)
951
+ - Much faster Sidekiq::Job#delete performance for larger queue sizes
952
+ - Further capistrano 3 fixes
953
+ - Many misc minor fixes
954
+
955
+ 2.16.1
956
+ -----------
957
+
958
+ - Revert usage of `resolv-replace`. MRI's native DNS lookup releases the GIL.
959
+ - Fix several Capistrano 3 issues
960
+ - Escaping dynamic data like job args and error messages in Sidekiq Web UI. [#1299, lian]
961
+
962
+ 2.16.0
963
+ -----------
964
+
965
+ - Deprecate `Sidekiq::Client.registered_workers` and `Sidekiq::Client.registered_queues`
966
+ - Refactor Sidekiq::Client to be instance-based [#1279]
967
+ - Pass all Redis options to the Redis driver so Unix sockets
968
+ can be fully configured. [#1270, salimane]
969
+ - Allow sidekiq-web extensions to add locale paths so extensions
970
+ can be localized. [#1261, ondrejbartas]
971
+ - Capistrano 3 support [#1254, phallstrom]
972
+ - Use Ruby's `resolv-replace` to enable pure Ruby DNS lookups.
973
+ This ensures that any DNS resolution that takes place in worker
974
+ threads won't lock up the entire VM on MRI. [#1258]
975
+
976
+ 2.15.2
977
+ -----------
978
+
979
+ - Iterating over Sidekiq::Queue and Sidekiq::SortedSet will now work as
980
+ intended when jobs are deleted [#866, aackerman]
981
+ - A few more minor Web UI fixes [#1247]
982
+
983
+ 2.15.1
984
+ -----------
985
+
986
+ - Fix several Web UI issues with the Bootstrap 3 upgrade.
987
+
988
+ 2.15.0
989
+ -----------
990
+
991
+ - The Core Sidekiq actors are now monitored. If any crash, the
992
+ Sidekiq process logs the error and exits immediately. This is to
993
+ help prevent "stuck" Sidekiq processes which are running but don't
994
+ appear to be doing any work. [#1194]
995
+ - Sidekiq's testing behavior is now dynamic. You can choose between
996
+ `inline` and `fake` behavior in your tests. See
997
+ [Testing](https://github.com/mperham/sidekiq/wiki/Testing) for detail. [#1193]
998
+ - The Retries table has a new column for the error message.
999
+ - The Web UI topbar now contains the status and live poll button.
1000
+ - Orphaned worker records are now auto-vacuumed when you visit the
1001
+ Workers page in the Web UI.
1002
+ - Sidekiq.default\_worker\_options allows you to configure default
1003
+ options for all Sidekiq worker types.
1004
+
1005
+ ```ruby
1006
+ Sidekiq.default_worker_options = { 'queue' => 'default', 'backtrace' => true }
1007
+ ```
1008
+ - Added two Sidekiq::Client class methods for compatibility with resque-scheduler:
1009
+ `enqueue_to_in` and `enqueue_in` [#1212]
1010
+ - Upgrade Web UI to Bootstrap 3.0. [#1211, jeffboek]
1011
+
1012
+ 2.14.1
1013
+ -----------
1014
+
1015
+ - Fix misc Web UI issues due to ERB conversion.
1016
+ - Bump redis-namespace version due to security issue.
1017
+
1018
+ 2.14.0
1019
+ -----------
1020
+
1021
+ - Removed slim gem dependency, Web UI now uses ERB [Locke23rus, #1120]
1022
+ - Fix more race conditions in Web UI actions
1023
+ - Don't reset Job enqueued\_at when retrying
1024
+ - Timestamp tooltips in the Web UI should use UTC
1025
+ - Fix invalid usage of handle\_exception causing issues in Airbrake
1026
+ [#1134]
1027
+
1028
+
1029
+ 2.13.1
1030
+ -----------
1031
+
1032
+ - Make Sidekiq::Middleware::Chain Enumerable
1033
+ - Make summary bar and graphs responsive [manishval, #1025]
1034
+ - Adds a job status page for scheduled jobs [jonhyman]
1035
+ - Handle race condition in retrying and deleting jobs in the Web UI
1036
+ - The Web UI relative times are now i18n. [MadRabbit, #1088]
1037
+ - Allow for default number of retry attempts to be set for
1038
+ `Sidekiq::Middleware::Server::RetryJobs` middleware. [czarneckid] [#1091]
1039
+
1040
+ ```ruby
1041
+ Sidekiq.configure_server do |config|
1042
+ config.server_middleware do |chain|
1043
+ chain.add Sidekiq::Middleware::Server::RetryJobs, :max_retries => 10
1044
+ end
1045
+ end
1046
+ ```
1047
+
1048
+
1049
+ 2.13.0
1050
+ -----------
1051
+
1052
+ - Adding button to move scheduled job to main queue [guiceolin, #1020]
1053
+ - fix i18n support resetting saved locale when job is retried [#1011]
1054
+ - log rotation via USR2 now closes the old logger [#1008]
1055
+ - Add ability to customize retry schedule, like so [jmazzi, #1027]
1056
+
1057
+ ```ruby
1058
+ class MyWorker
1059
+ include Sidekiq::Worker
1060
+ sidekiq_retry_in { |count| count * 2 }
1061
+ end
1062
+ ```
1063
+ - Redesign Worker#retries\_exhausted callback to use same form as above [jmazzi, #1030]
1064
+
1065
+ ```ruby
1066
+ class MyWorker
1067
+ include Sidekiq::Worker
1068
+ sidekiq_retries_exhausted do |msg|
1069
+ Rails.logger.error "Failed to process #{msg['class']} with args: #{msg['args']}"
1070
+ end
1071
+ end
1072
+ ```
1073
+
1074
+ 2.12.4
1075
+ -----------
1076
+
1077
+ - Fix error in previous release which crashed the Manager when a
1078
+ Processor died.
1079
+
1080
+ 2.12.3
1081
+ -----------
1082
+
1083
+ - Revert back to Celluloid's TaskFiber for job processing which has proven to be more
1084
+ stable than TaskThread. [#985]
1085
+ - Avoid possible lockup during hard shutdown [#997]
1086
+
1087
+ At this point, if you are experiencing stability issues with Sidekiq in
1088
+ Ruby 1.9, please try Ruby 2.0. It seems to be more stable.
1089
+
1090
+ 2.12.2
1091
+ -----------
1092
+
1093
+ - Relax slim version requirement to >= 1.1.0
1094
+ - Refactor historical stats to use TTL, not explicit cleanup. [grosser, #971]
1095
+
1096
+ 2.12.1
1097
+ -----------
1098
+
1099
+ - Force Celluloid 0.14.1 as 0.14.0 has a serious bug. [#954]
1100
+ - Scheduled and Retry jobs now use Sidekiq::Client to push
1101
+ jobs onto the queue, so they use client middleware. [dimko, #948]
1102
+ - Record the timestamp when jobs are enqueued. Add
1103
+ Sidekiq::Job#enqueued\_at to query the time. [mariovisic, #944]
1104
+ - Add Sidekiq::Queue#latency - calculates diff between now and
1105
+ enqueued\_at for the oldest job in the queue.
1106
+ - Add testing method `perform_one` that dequeues and performs a single job.
1107
+ This is mainly to aid testing jobs that spawn other jobs. [fumin, #963]
1108
+
1109
+ 2.12.0
1110
+ -----------
1111
+
1112
+ - Upgrade to Celluloid 0.14, remove the use of Celluloid's thread
1113
+ pool. This should halve the number of threads in each Sidekiq
1114
+ process, thus requiring less resources. [#919]
1115
+ - Abstract Celluloid usage to Sidekiq::Actor for testing purposes.
1116
+ - Better handling for Redis downtime when fetching jobs and shutting
1117
+ down, don't print exceptions every second and print success message
1118
+ when Redis is back.
1119
+ - Fix unclean shutdown leading to duplicate jobs [#897]
1120
+ - Add Korean locale [#890]
1121
+ - Upgrade test suite to Minitest 5
1122
+ - Remove usage of `multi_json` as `json` is now robust on all platforms.
1123
+
1124
+ 2.11.2
1125
+ -----------
1126
+
1127
+ - Fix Web UI when used without Rails [#886]
1128
+ - Add Sidekiq::Stats#reset [#349]
1129
+ - Add Norwegian locale.
1130
+ - Updates for the JA locale.
1131
+
1132
+ 2.11.1
1133
+ -----------
1134
+
1135
+ - Fix timeout warning.
1136
+ - Add Dutch web UI locale.
1137
+
1138
+ 2.11.0
1139
+ -----------
1140
+
1141
+ - Upgrade to Celluloid 0.13. [#834]
1142
+ - Remove **timeout** support from `sidekiq_options`. Ruby's timeout
1143
+ is inherently unsafe in a multi-threaded application and was causing
1144
+ stability problems for many. See http://bit.ly/OtYpK
1145
+ - Add Japanese locale for Web UI [#868]
1146
+ - Fix a few issues with Web UI i18n.
1147
+
1148
+ 2.10.1
1149
+ -----------
1150
+
1151
+ - Remove need for the i18n gem. (brandonhilkert)
1152
+ - Improve redis connection info logging on startup for debugging
1153
+ purposes [#858]
1154
+ - Revert sinatra/slim as runtime dependencies
1155
+ - Add `find_job` method to sidekiq/api
1156
+
1157
+
1158
+ 2.10.0
1159
+ -----------
1160
+
1161
+ - Refactor algorithm for putting scheduled jobs onto the queue [#843]
1162
+ - Fix scheduler thread dying due to incorrect error handling [#839]
1163
+ - Fix issue which left stale workers if Sidekiq wasn't shutdown while
1164
+ quiet. [#840]
1165
+ - I18n for web UI. Please submit translations of `web/locales/en.yml` for
1166
+ your own language. [#811]
1167
+ - 'sinatra', 'slim' and 'i18n' are now gem dependencies for Sidekiq.
1168
+
1169
+
1170
+ 2.9.0
1171
+ -----------
1172
+
1173
+ - Update 'sidekiq/testing' to work with any Sidekiq::Client call. It
1174
+ also serializes the arguments as using Redis would. [#713]
1175
+ - Raise a Sidekiq::Shutdown error within workers which don't finish within the hard
1176
+ timeout. This is to prevent unwanted database transaction commits. [#377]
1177
+ - Lazy load Redis connection pool, you no longer need to specify
1178
+ anything in Passenger or Unicorn's after_fork callback [#794]
1179
+ - Add optional Worker#retries_exhausted hook after max retries failed. [jkassemi, #780]
1180
+ - Fix bug in pagination link to last page [pitr, #774]
1181
+ - Upstart scripts for multiple Sidekiq instances [dariocravero, #763]
1182
+ - Use select via pipes instead of poll to catch signals [mrnugget, #761]
1183
+
1184
+ 2.8.0
1185
+ -----------
1186
+
1187
+ - I18n support! Sidekiq can optionally save and restore the Rails locale
1188
+ so it will be properly set when your jobs execute. Just include
1189
+ `require 'sidekiq/middleware/i18n'` in your sidekiq initializer. [#750]
1190
+ - Fix bug which could lose messages when using namespaces and the message
1191
+ needs to be requeued in Redis. [#744]
1192
+ - Refactor Redis namespace support [#747]. The redis namespace can no longer be
1193
+ passed via the config file, the only supported way is via Ruby in your
1194
+ initializer:
1195
+
1196
+ ```ruby
1197
+ sidekiq_redis = { :url => 'redis://localhost:3679', :namespace => 'foo' }
1198
+ Sidekiq.configure_server { |config| config.redis = sidekiq_redis }
1199
+ Sidekiq.configure_client { |config| config.redis = sidekiq_redis }
1200
+ ```
1201
+
1202
+ A warning is printed out to the log if a namespace is found in your sidekiq.yml.
1203
+
1204
+
1205
+ 2.7.5
1206
+ -----------
1207
+
1208
+ - Capistrano no longer uses daemonization in order to work with JRuby [#719]
1209
+ - Refactor signal handling to work on Ruby 2.0 [#728, #730]
1210
+ - Fix dashboard refresh URL [#732]
1211
+
1212
+ 2.7.4
1213
+ -----------
1214
+
1215
+ - Fixed daemonization, was broken by some internal refactoring in 2.7.3 [#727]
1216
+
1217
+ 2.7.3
1218
+ -----------
1219
+
1220
+ - Real-time dashboard is now the default web page
1221
+ - Make config file optional for capistrano
1222
+ - Fix Retry All button in the Web UI
1223
+
1224
+ 2.7.2
1225
+ -----------
1226
+
1227
+ - Remove gem signing infrastructure. It was causing Sidekiq to break
1228
+ when used via git in Bundler. This is why we can't have nice things. [#688]
1229
+
1230
+
1231
+ 2.7.1
1232
+ -----------
1233
+
1234
+ - Fix issue with hard shutdown [#680]
1235
+
1236
+
1237
+ 2.7.0
1238
+ -----------
1239
+
1240
+ - Add -d daemonize flag, capistrano recipe has been updated to use it [#662]
1241
+ - Support profiling via `ruby-prof` with -p. When Sidekiq is stopped
1242
+ via Ctrl-C, it will output `profile.html`. You must add `gem 'ruby-prof'` to your Gemfile for it to work.
1243
+ - Dynamically update Redis stats on dashboard [brandonhilkert]
1244
+ - Add Sidekiq::Workers API giving programmatic access to the current
1245
+ set of active workers.
1246
+
1247
+ ```
1248
+ workers = Sidekiq::Workers.new
1249
+ workers.size => 2
1250
+ workers.each do |name, work|
1251
+ # name is a unique identifier per Processor instance
1252
+ # work is a Hash which looks like:
1253
+ # { 'queue' => name, 'run_at' => timestamp, 'payload' => msg }
1254
+ end
1255
+ ```
1256
+
1257
+ - Allow environment-specific sections within the config file which
1258
+ override the global values [dtaniwaki, #630]
1259
+
1260
+ ```
1261
+ ---
1262
+ :concurrency: 50
1263
+ :verbose: false
1264
+ staging:
1265
+ :verbose: true
1266
+ :concurrency: 5
1267
+ ```
1268
+
1269
+
1270
+ 2.6.5
1271
+ -----------
1272
+
1273
+ - Several reliability fixes for job requeueing upon termination [apinstein, #622, #624]
1274
+ - Fix typo in capistrano recipe
1275
+ - Add `retry_queue` option so retries can be given lower priority [ryanlower, #620]
1276
+
1277
+ ```ruby
1278
+ sidekiq_options queue: 'high', retry_queue: 'low'
1279
+ ```
1280
+
1281
+ 2.6.4
1282
+ -----------
1283
+
1284
+ - Fix crash upon empty queue [#612]
1285
+
1286
+ 2.6.3
1287
+ -----------
1288
+
1289
+ - sidekiqctl exits with non-zero exit code upon error [jmazzi]
1290
+ - better argument validation in Sidekiq::Client [karlfreeman]
1291
+
1292
+ 2.6.2
1293
+ -----------
1294
+
1295
+ - Add Dashboard beacon indicating when stats are updated. [brandonhilkert, #606]
1296
+ - Revert issue with capistrano restart. [#598]
1297
+
1298
+ 2.6.1
1299
+ -----------
1300
+
1301
+ - Dashboard now live updates summary stats also. [brandonhilkert, #605]
1302
+ - Add middleware chain APIs `insert_before` and `insert_after` for fine
1303
+ tuning the order of middleware. [jackrg, #595]
1304
+
1305
+ 2.6.0
1306
+ -----------
1307
+
1308
+ - Web UI much more mobile friendly now [brandonhilkert, #573]
1309
+ - Enable live polling for every section in Web UI [brandonhilkert, #567]
1310
+ - Add Stats API [brandonhilkert, #565]
1311
+ - Add Stats::History API [brandonhilkert, #570]
1312
+ - Add Dashboard to Web UI with live and historical stat graphs [brandonhilkert, #580]
1313
+ - Add option to log output to a file, reopen log file on USR2 signal [mrnugget, #581]
1314
+
1315
+ 2.5.4
1316
+ -----------
1317
+
1318
+ - `Sidekiq::Client.push` now accepts the worker class as a string so the
1319
+ Sidekiq client does not have to load your worker classes at all. [#524]
1320
+ - `Sidekiq::Client.push_bulk` now works with inline testing.
1321
+ - **Really** fix status icon in Web UI this time.
1322
+ - Add "Delete All" and "Retry All" buttons to Retries in Web UI
1323
+
1324
+
1325
+ 2.5.3
1326
+ -----------
1327
+
1328
+ - Small Web UI fixes
1329
+ - Add `delay_until` so you can delay jobs until a specific timestamp:
1330
+
1331
+ ```ruby
1332
+ Auction.delay_until(@auction.ends_at).close(@auction.id)
1333
+ ```
1334
+
1335
+ This is identical to the existing Sidekiq::Worker method, `perform_at`.
1336
+
1337
+ 2.5.2
1338
+ -----------
1339
+
1340
+ - Remove asset pipeline from Web UI for much faster, simpler runtime. [#499, #490, #481]
1341
+ - Add -g option so the procline better identifies a Sidekiq process, defaults to File.basename(Rails.root). [#486]
1342
+
1343
+ sidekiq 2.5.1 myapp [0 of 25 busy]
1344
+
1345
+ - Add splay to retry time so groups of failed jobs don't fire all at once. [#483]
1346
+
1347
+ 2.5.1
1348
+ -----------
1349
+
1350
+ - Fix issues with core\_ext
1351
+
1352
+ 2.5.0
1353
+ -----------
1354
+
1355
+ - REDESIGNED WEB UI! [unity, cavneb]
1356
+ - Support Honeybadger for error delivery
1357
+ - Inline testing runs the client middleware before executing jobs [#465]
1358
+ - Web UI can now remove jobs from queue. [#466, dleung]
1359
+ - Web UI can now show the full message, not just 100 chars [#464, dleung]
1360
+ - Add APIs for manipulating the retry and job queues. See sidekiq/api. [#457]
1361
+
1362
+
1363
+ 2.4.0
1364
+ -----------
1365
+
1366
+ - ActionMailer.delay.method now only tries to deliver if method returns a valid message.
1367
+ - Logging now uses "MSG-#{Job ID}", not a random msg ID
1368
+ - Allow generic Redis provider as environment variable. [#443]
1369
+ - Add ability to customize sidekiq\_options with delay calls [#450]
1370
+
1371
+ ```ruby
1372
+ Foo.delay(:retry => false).bar
1373
+ Foo.delay(:retry => 10).bar
1374
+ Foo.delay(:timeout => 10.seconds).bar
1375
+ Foo.delay_for(5.minutes, :timeout => 10.seconds).bar
1376
+ ```
1377
+
1378
+ 2.3.3
1379
+ -----------
1380
+
1381
+ - Remove option to disable Rails hooks. [#401]
1382
+ - Allow delay of any module class method
1383
+
1384
+ 2.3.2
1385
+ -----------
1386
+
1387
+ - Fix retry. 2.3.1 accidentally disabled it.
1388
+
1389
+ 2.3.1
1390
+ -----------
1391
+
1392
+ - Add Sidekiq::Client.push\_bulk for bulk adding of jobs to Redis.
1393
+ My own simple test case shows pushing 10,000 jobs goes from 5 sec to 1.5 sec.
1394
+ - Add support for multiple processes per host to Capistrano recipe
1395
+ - Re-enable Celluloid::Actor#defer to fix stack overflow issues [#398]
1396
+
1397
+ 2.3.0
1398
+ -----------
1399
+
1400
+ - Upgrade Celluloid to 0.12
1401
+ - Upgrade Twitter Bootstrap to 2.1.0
1402
+ - Rescue more Exceptions
1403
+ - Change Job ID to be Hex, rather than Base64, for HTTP safety
1404
+ - Use `Airbrake#notify_or_ignore`
1405
+
1406
+ 2.2.1
1407
+ -----------
1408
+
1409
+ - Add support for custom tabs to Sidekiq::Web [#346]
1410
+ - Change capistrano recipe to run 'quiet' before deploy:update\_code so
1411
+ it is run upon both 'deploy' and 'deploy:migrations'. [#352]
1412
+ - Rescue Exception rather than StandardError to catch and log any sort
1413
+ of Processor death.
1414
+
1415
+ 2.2.0
1416
+ -----------
1417
+
1418
+ - Roll back Celluloid optimizations in 2.1.0 which caused instability.
1419
+ - Add extension to delay any arbitrary class method to Sidekiq.
1420
+ Previously this was limited to ActiveRecord classes.
1421
+
1422
+ ```ruby
1423
+ SomeClass.delay.class_method(1, 'mike', Date.today)
1424
+ ```
1425
+
1426
+ - Sidekiq::Client now generates and returns a random, 128-bit Job ID 'jid' which
1427
+ can be used to track the processing of a Job, e.g. for calling back to a webhook
1428
+ when a job is finished.
1429
+
1430
+ 2.1.1
1431
+ -----------
1432
+
1433
+ - Handle networking errors causing the scheduler thread to die [#309]
1434
+ - Rework exception handling to log all Processor and actor death (#325, subelsky)
1435
+ - Clone arguments when calling worker so modifications are discarded. (#265, hakanensari)
1436
+
1437
+ 2.1.0
1438
+ -----------
1439
+
1440
+ - Tune Celluloid to no longer run message processing within a Fiber.
1441
+ This gives us a full Thread stack and also lowers Sidekiq's memory
1442
+ usage.
1443
+ - Add pagination within the Web UI [#253]
1444
+ - Specify which Redis driver to use: *hiredis* or *ruby* (default)
1445
+ - Remove FailureJobs and UniqueJobs, which were optional middleware
1446
+ that I don't want to support in core. [#302]
1447
+
1448
+ 2.0.3
1449
+ -----------
1450
+ - Fix sidekiq-web's navbar on mobile devices and windows under 980px (ezkl)
1451
+ - Fix Capistrano task for first deploys [#259]
1452
+ - Worker subclasses now properly inherit sidekiq\_options set in
1453
+ their superclass [#221]
1454
+ - Add random jitter to scheduler to spread polls across POLL\_INTERVAL
1455
+ window. [#247]
1456
+ - Sidekiq has a new mailing list: sidekiq@librelist.org See README.
1457
+
1458
+ 2.0.2
1459
+ -----------
1460
+
1461
+ - Fix "Retry Now" button on individual retry page. (ezkl)
1462
+
1463
+ 2.0.1
1464
+ -----------
1465
+
1466
+ - Add "Clear Workers" button to UI. If you kill -9 Sidekiq, the workers
1467
+ set can fill up with stale entries.
1468
+ - Update sidekiq/testing to support new scheduled jobs API:
1469
+
1470
+ ```ruby
1471
+ require 'sidekiq/testing'
1472
+ DirectWorker.perform_in(10.seconds, 1, 2)
1473
+ assert_equal 1, DirectWorker.jobs.size
1474
+ assert_in_delta 10.seconds.from_now.to_f, DirectWorker.jobs.last['at'], 0.01
1475
+ ```
1476
+
1477
+ 2.0.0
1478
+ -----------
1479
+
1480
+ - **SCHEDULED JOBS**!
1481
+
1482
+ You can now use `perform_at` and `perform_in` to schedule jobs
1483
+ to run at arbitrary points in the future, like so:
1484
+
1485
+ ```ruby
1486
+ SomeWorker.perform_in(5.days, 'bob', 13)
1487
+ SomeWorker.perform_at(5.days.from_now, 'bob', 13)
1488
+ ```
1489
+
1490
+ It also works with the delay extensions:
1491
+
1492
+ ```ruby
1493
+ UserMailer.delay_for(5.days).send_welcome_email(user.id)
1494
+ ```
1495
+
1496
+ The time is approximately when the job will be placed on the queue;
1497
+ it is not guaranteed to run at precisely at that moment in time.
1498
+
1499
+ This functionality is meant for one-off, arbitrary jobs. I still
1500
+ recommend `whenever` or `clockwork` if you want cron-like,
1501
+ recurring jobs. See `examples/scheduling.rb`
1502
+
1503
+ I want to specially thank @yabawock for his work on sidekiq-scheduler.
1504
+ His extension for Sidekiq 1.x filled an obvious functional gap that I now think is
1505
+ useful enough to implement in Sidekiq proper.
1506
+
1507
+ - Fixed issues due to Redis 3.x API changes. Sidekiq now requires
1508
+ the Redis 3.x client.
1509
+ - Inline testing now round trips arguments through JSON to catch
1510
+ serialization issues (betelgeuse)
1511
+
1512
+ 1.2.1
1513
+ -----------
1514
+
1515
+ - Sidekiq::Worker now has access to Sidekiq's standard logger
1516
+ - Fix issue with non-StandardErrors leading to Processor exhaustion
1517
+ - Fix issue with Fetcher slowing Sidekiq shutdown
1518
+ - Print backtraces for all threads upon TTIN signal [#183]
1519
+ - Overhaul retries Web UI with new index page and bulk operations [#184]
1520
+
1521
+ 1.2.0
1522
+ -----------
1523
+
1524
+ - Full or partial error backtraces can optionally be stored as part of the retry
1525
+ for display in the web UI if you aren't using an error service. [#155]
1526
+
1527
+ ```ruby
1528
+ class Worker
1529
+ include Sidekiq::Worker
1530
+ sidekiq_options :backtrace => [true || 10]
1531
+ end
1532
+ ```
1533
+ - Add timeout option to kill a worker after N seconds (blackgold9)
1534
+
1535
+ ```ruby
1536
+ class HangingWorker
1537
+ include Sidekiq::Worker
1538
+ sidekiq_options :timeout => 600
1539
+ def perform
1540
+ # will be killed if it takes longer than 10 minutes
1541
+ end
1542
+ end
1543
+ ```
1544
+
1545
+ - Fix delayed extensions not available in workers [#152]
1546
+ - In test environments add the `#drain` class method to workers. This method
1547
+ executes all previously queued jobs. (panthomakos)
1548
+ - Sidekiq workers can be run inline during tests, just `require 'sidekiq/testing/inline'` (panthomakos)
1549
+ - Queues can now be deleted from the Sidekiq web UI [#154]
1550
+ - Fix unnecessary shutdown delay due to Retry Poller [#174]
1551
+
1552
+ 1.1.4
1553
+ -----------
1554
+
1555
+ - Add 24 hr expiry for basic keys set in Redis, to avoid any possible leaking.
1556
+ - Only register workers in Redis while working, to avoid lingering
1557
+ workers [#156]
1558
+ - Speed up shutdown significantly.
1559
+
1560
+ 1.1.3
1561
+ -----------
1562
+
1563
+ - Better network error handling when fetching jobs from Redis.
1564
+ Sidekiq will retry once per second until it can re-establish
1565
+ a connection. (ryanlecompte)
1566
+ - capistrano recipe now uses `bundle_cmd` if set [#147]
1567
+ - handle multi\_json API changes (sferik)
1568
+
1569
+ 1.1.2
1570
+ -----------
1571
+
1572
+ - Fix double restart with cap deploy [#137]
1573
+
1574
+ 1.1.1
1575
+ -----------
1576
+
1577
+ - Set procline for easy monitoring of Sidekiq status via "ps aux"
1578
+ - Fix race condition on shutdown [#134]
1579
+ - Fix hang with cap sidekiq:start [#131]
1580
+
1581
+ 1.1.0
1582
+ -----------
1583
+
1584
+ - The Sidekiq license has switched from GPLv3 to LGPLv3!
1585
+ - Sidekiq::Client.push now returns whether the actual Redis
1586
+ operation succeeded or not. [#123]
1587
+ - Remove UniqueJobs from the default middleware chain. Its
1588
+ functionality, while useful, is unexpected for new Sidekiq
1589
+ users. You can re-enable it with the following config.
1590
+ Read #119 for more discussion.
1591
+
1592
+ ```ruby
1593
+ Sidekiq.configure_client do |config|
1594
+ require 'sidekiq/middleware/client/unique_jobs'
1595
+ config.client_middleware do |chain|
1596
+ chain.add Sidekiq::Middleware::Client::UniqueJobs
1597
+ end
1598
+ end
1599
+ Sidekiq.configure_server do |config|
1600
+ require 'sidekiq/middleware/server/unique_jobs'
1601
+ config.server_middleware do |chain|
1602
+ chain.add Sidekiq::Middleware::Server::UniqueJobs
1603
+ end
1604
+ end
1605
+ ```
1606
+
1607
+ 1.0.0
1608
+ -----------
1609
+
1610
+ Thanks to all Sidekiq users and contributors for helping me
1611
+ get to this big milestone!
1612
+
1613
+ - Default concurrency on client-side to 5, not 25 so we don't
1614
+ create as many unused Redis connections, same as ActiveRecord's
1615
+ default pool size.
1616
+ - Ensure redis= is given a Hash or ConnectionPool.
1617
+
1618
+ 0.11.2
1619
+ -----------
1620
+
1621
+ - Implement "safe shutdown". The messages for any workers that
1622
+ are still busy when we hit the TERM timeout will be requeued in
1623
+ Redis so the messages are not lost when the Sidekiq process exits.
1624
+ [#110]
1625
+ - Work around Celluloid's small 4kb stack limit [#115]
1626
+ - Add support for a custom Capistrano role to limit Sidekiq to
1627
+ a set of machines. [#113]
1628
+
1629
+ 0.11.1
1630
+ -----------
1631
+
1632
+ - Fix fetch breaking retry when used with Redis namespaces. [#109]
1633
+ - Redis connection now just a plain ConnectionPool, not CP::Wrapper.
1634
+ - Capistrano initial deploy fix [#106]
1635
+ - Re-implemented weighted queues support (ryanlecompte)
1636
+
1637
+ 0.11.0
1638
+ -----------
1639
+
1640
+ - Client-side API changes, added sidekiq\_options for Sidekiq::Worker.
1641
+ As a side effect of this change, the client API works on Ruby 1.8.
1642
+ It's not officially supported but should work [#103]
1643
+ - NO POLL! Sidekiq no longer polls Redis, leading to lower network
1644
+ utilization and lower latency for message processing.
1645
+ - Add --version CLI option
1646
+
1647
+ 0.10.1
1648
+ -----------
1649
+
1650
+ - Add details page for jobs in retry queue (jcoene)
1651
+ - Display relative timestamps in web interface (jcoene)
1652
+ - Capistrano fixes (hinrik, bensie)
1653
+
1654
+ 0.10.0
1655
+ -----------
1656
+
1657
+ - Reworked capistrano recipe to make it more fault-tolerant [#94].
1658
+ - Automatic failure retry! Sidekiq will now save failed messages
1659
+ and retry them, with an exponential backoff, over about 20 days.
1660
+ Did a message fail to process? Just deploy a bug fix in the next
1661
+ few days and Sidekiq will retry the message eventually.
1662
+
1663
+ 0.9.1
1664
+ -----------
1665
+
1666
+ - Fix missed deprecations, poor method name in web UI
1667
+
1668
+ 0.9.0
1669
+ -----------
1670
+
1671
+ - Add -t option to configure the TERM shutdown timeout
1672
+ - TERM shutdown timeout is now configurable, defaults to 5 seconds.
1673
+ - USR1 signal now stops Sidekiq from accepting new work,
1674
+ capistrano sends USR1 at start of deploy and TERM at end of deploy
1675
+ giving workers the maximum amount of time to finish.
1676
+ - New Sidekiq::Web rack application available
1677
+ - Updated Sidekiq.redis API
1678
+
1679
+ 0.8.0
1680
+ -----------
1681
+
1682
+ - Remove :namespace and :server CLI options (mperham)
1683
+ - Add ExceptionNotifier support (masterkain)
1684
+ - Add capistrano support (mperham)
1685
+ - Workers now log upon start and finish (mperham)
1686
+ - Messages for terminated workers are now automatically requeued (mperham)
1687
+ - Add support for Exceptional error reporting (bensie)
1688
+
1689
+ 0.7.0
1690
+ -----------
1691
+
1692
+ - Example chef recipe and monitrc script (jc00ke)
1693
+ - Refactor global configuration into Sidekiq.configure\_server and
1694
+ Sidekiq.configure\_client blocks. (mperham)
1695
+ - Add optional middleware FailureJobs which saves failed jobs to a
1696
+ 'failed' queue (fbjork)
1697
+ - Upon shutdown, workers are now terminated after 5 seconds. This is to
1698
+ meet Heroku's hard limit of 10 seconds for a process to shutdown. (mperham)
1699
+ - Refactor middleware API for simplicity, see sidekiq/middleware/chain. (mperham)
1700
+ - Add `delay` extensions for ActionMailer and ActiveRecord. (mperham)
1701
+ - Added config file support. See test/config.yml for an example file. (jc00ke)
1702
+ - Added pidfile for tools like monit (jc00ke)
1703
+
1704
+ 0.6.0
1705
+ -----------
1706
+
1707
+ - Resque-compatible processing stats in redis (mperham)
1708
+ - Simple client testing support in sidekiq/testing (mperham)
1709
+ - Plain old Ruby support via the -r cli flag (mperham)
1710
+ - Refactored middleware support, introducing ability to add client-side middleware (ryanlecompte)
1711
+ - Added middleware for ignoring duplicate jobs (ryanlecompte)
1712
+ - Added middleware for displaying jobs in resque-web dashboard (maxjustus)
1713
+ - Added redis namespacing support (maxjustus)
1714
+
1715
+ 0.5.1
1716
+ -----------
1717
+
1718
+ - Initial release!