sidekiq 5.2.9 → 6.1.2

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 (89) hide show
  1. checksums.yaml +4 -4
  2. data/.github/ISSUE_TEMPLATE/bug_report.md +20 -0
  3. data/.github/workflows/ci.yml +41 -0
  4. data/.gitignore +0 -2
  5. data/.standard.yml +20 -0
  6. data/6.0-Upgrade.md +72 -0
  7. data/Changes.md +184 -0
  8. data/Ent-2.0-Upgrade.md +37 -0
  9. data/Ent-Changes.md +44 -1
  10. data/Gemfile +12 -11
  11. data/Gemfile.lock +192 -0
  12. data/Pro-5.0-Upgrade.md +25 -0
  13. data/Pro-Changes.md +48 -2
  14. data/README.md +18 -34
  15. data/Rakefile +5 -4
  16. data/bin/sidekiq +26 -2
  17. data/bin/sidekiqload +32 -24
  18. data/bin/sidekiqmon +8 -0
  19. data/lib/generators/sidekiq/templates/worker_test.rb.erb +1 -1
  20. data/lib/generators/sidekiq/worker_generator.rb +21 -13
  21. data/lib/sidekiq/api.rb +242 -219
  22. data/lib/sidekiq/cli.rb +131 -180
  23. data/lib/sidekiq/client.rb +67 -47
  24. data/lib/sidekiq/delay.rb +5 -6
  25. data/lib/sidekiq/exception_handler.rb +10 -12
  26. data/lib/sidekiq/extensions/action_mailer.rb +13 -22
  27. data/lib/sidekiq/extensions/active_record.rb +13 -10
  28. data/lib/sidekiq/extensions/class_methods.rb +14 -11
  29. data/lib/sidekiq/extensions/generic_proxy.rb +4 -4
  30. data/lib/sidekiq/fetch.rb +29 -30
  31. data/lib/sidekiq/job_logger.rb +45 -7
  32. data/lib/sidekiq/job_retry.rb +61 -61
  33. data/lib/sidekiq/launcher.rb +88 -55
  34. data/lib/sidekiq/logger.rb +165 -0
  35. data/lib/sidekiq/manager.rb +11 -13
  36. data/lib/sidekiq/middleware/chain.rb +15 -5
  37. data/lib/sidekiq/middleware/i18n.rb +5 -7
  38. data/lib/sidekiq/monitor.rb +133 -0
  39. data/lib/sidekiq/paginator.rb +18 -14
  40. data/lib/sidekiq/processor.rb +71 -70
  41. data/lib/sidekiq/rails.rb +29 -37
  42. data/lib/sidekiq/redis_connection.rb +50 -48
  43. data/lib/sidekiq/scheduled.rb +28 -29
  44. data/lib/sidekiq/sd_notify.rb +149 -0
  45. data/lib/sidekiq/systemd.rb +24 -0
  46. data/lib/sidekiq/testing/inline.rb +2 -1
  47. data/lib/sidekiq/testing.rb +35 -24
  48. data/lib/sidekiq/util.rb +17 -16
  49. data/lib/sidekiq/version.rb +2 -1
  50. data/lib/sidekiq/web/action.rb +14 -10
  51. data/lib/sidekiq/web/application.rb +73 -71
  52. data/lib/sidekiq/web/csrf_protection.rb +158 -0
  53. data/lib/sidekiq/web/helpers.rb +85 -77
  54. data/lib/sidekiq/web/router.rb +18 -17
  55. data/lib/sidekiq/web.rb +53 -53
  56. data/lib/sidekiq/worker.rb +126 -102
  57. data/lib/sidekiq.rb +69 -44
  58. data/sidekiq.gemspec +15 -16
  59. data/web/assets/javascripts/application.js +25 -27
  60. data/web/assets/javascripts/dashboard.js +4 -23
  61. data/web/assets/stylesheets/application-dark.css +143 -0
  62. data/web/assets/stylesheets/application.css +16 -6
  63. data/web/locales/de.yml +14 -2
  64. data/web/locales/en.yml +2 -0
  65. data/web/locales/fr.yml +2 -2
  66. data/web/locales/ja.yml +4 -1
  67. data/web/locales/lt.yml +83 -0
  68. data/web/locales/pl.yml +4 -4
  69. data/web/locales/ru.yml +4 -0
  70. data/web/locales/vi.yml +83 -0
  71. data/web/views/_job_info.erb +2 -1
  72. data/web/views/busy.erb +6 -3
  73. data/web/views/dead.erb +2 -2
  74. data/web/views/layout.erb +1 -0
  75. data/web/views/morgue.erb +5 -2
  76. data/web/views/queue.erb +10 -1
  77. data/web/views/queues.erb +9 -1
  78. data/web/views/retries.erb +5 -2
  79. data/web/views/retry.erb +2 -2
  80. data/web/views/scheduled.erb +5 -2
  81. metadata +25 -43
  82. data/.circleci/config.yml +0 -61
  83. data/.github/issue_template.md +0 -11
  84. data/.travis.yml +0 -11
  85. data/bin/sidekiqctl +0 -20
  86. data/lib/sidekiq/core_ext.rb +0 -1
  87. data/lib/sidekiq/ctl.rb +0 -221
  88. data/lib/sidekiq/logging.rb +0 -122
  89. data/lib/sidekiq/middleware/server/active_record.rb +0 -23
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 575db4e3e544aee9b13d0cd23610bf39c4167e3a9835d4c046a9b355d2cb9c0e
4
- data.tar.gz: 3f1f5806001515d03e206ce8d0695e59f9ff563ac5d84472294799424187591c
3
+ metadata.gz: 5a80310735fb458e7332a5ecc86072248e0777e1951f77f14965c06313c5b2f8
4
+ data.tar.gz: bfd09dc57c4506ca9c4d74dd9a38e88ef18700aafaf92814d662c6df4e4b2e5b
5
5
  SHA512:
6
- metadata.gz: 525fe03fcc6911d231696182d46de5da5d4c072681c924b14a0732aeb6aed3a1310baa4f9827f0f50925b69bede7218d485c4a81ebeb2feb712881b39da996e7
7
- data.tar.gz: 586fb51fff5bfefaa6db779e470b6040c8d98a2d4e8fb319cde6087c3f02ffc242ae0a067e32cb8f25585cd6d8d6c12e40f05507514b9406bdb1eadb3ac6f2dd
6
+ metadata.gz: c0e416fe575874c2051e88c64a6cbb30ad2ba4929ca33487ca1323b1963101d3d08ed43b8edbe874bccfa677521b0745baf589b451c7c56ff41b7bc70ee4f88d
7
+ data.tar.gz: 4d1cd6d03768f9844bd8edd9bdb545a743084322f4edc01682e04b0990b0fb6aa3f1c6ad4f9a87c1b810a07e03b08eae0405ad2291b42d58eebb257bed7a60f4
@@ -0,0 +1,20 @@
1
+ ---
2
+ name: Bug report
3
+ about: Create a report to help us improve
4
+ title: ''
5
+ labels: ''
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ Ruby version:
11
+ Rails version:
12
+ Sidekiq / Pro / Enterprise version(s):
13
+
14
+ Please include your initializer, sidekiq.yml, and any error message with the full backtrace.
15
+
16
+ If you are using an old version, have you checked the changelogs to see if your issue has been fixed in a later version?
17
+
18
+ https://github.com/mperham/sidekiq/blob/master/Changes.md
19
+ https://github.com/mperham/sidekiq/blob/master/Pro-Changes.md
20
+ https://github.com/mperham/sidekiq/blob/master/Ent-Changes.md
@@ -0,0 +1,41 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [ master ]
6
+ pull_request:
7
+ branches: [ master ]
8
+
9
+ jobs:
10
+ test:
11
+
12
+ runs-on: ubuntu-latest
13
+
14
+ strategy:
15
+ fail-fast: false
16
+ matrix:
17
+ ruby: [2.5, 2.6, 2.7]
18
+ services:
19
+ redis:
20
+ image: redis
21
+ options: >-
22
+ --health-cmd "redis-cli ping"
23
+ --health-interval 10s
24
+ --health-timeout 5s
25
+ --health-retries 5
26
+ ports:
27
+ - 6379:6379
28
+
29
+ steps:
30
+ - uses: actions/checkout@v2
31
+ - name: Set up Ruby
32
+ # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
33
+ # change this to (see https://github.com/ruby/setup-ruby#versioning):
34
+ uses: ruby/setup-ruby@v1
35
+ with:
36
+ bundler-cache: true
37
+ ruby-version: ${{ matrix.ruby }}
38
+ - name: Install dependencies
39
+ run: bundle install
40
+ - name: Run tests
41
+ run: bundle exec rake
data/.gitignore CHANGED
@@ -1,8 +1,6 @@
1
1
  .rvmrc
2
2
  .ruby-version
3
3
  tags
4
- Gemfile.lock
5
- gemfiles/*.lock
6
4
  *.swp
7
5
  dump.rdb
8
6
  .rbx
data/.standard.yml ADDED
@@ -0,0 +1,20 @@
1
+ ruby_version: 2.5.0
2
+ fix: false
3
+ parallel: true
4
+ ignore:
5
+ - test/**/*
6
+ - examples/**/*
7
+ - myapp/**/*
8
+ - 'lib/sidekiq.rb':
9
+ - Lint/InheritException
10
+ - 'lib/sidekiq/extensions/**/*':
11
+ - Style/MethodMissingSuper
12
+ - Style/MissingRespondToMissing
13
+ - 'lib/**/*':
14
+ - Naming/AsciiIdentifiers
15
+ - Lint/RescueException
16
+ - Security/YAMLLoad
17
+ - Naming/AccessorMethodName
18
+ - Naming/MethodName
19
+ - Style/GlobalVars
20
+ - Style/Alias
data/6.0-Upgrade.md ADDED
@@ -0,0 +1,72 @@
1
+ # Welcome to Sidekiq 6.0!
2
+
3
+ Sidekiq 6.0 contains some breaking changes which streamline proper operation
4
+ of Sidekiq. It also drops support for EOL versions of Ruby and Rails.
5
+
6
+ ## What's New
7
+
8
+ This release has major breaking changes. Read and test carefully in production.
9
+
10
+ - ActiveJobs can now use `sidekiq_options` directly to configure Sidekiq
11
+ features/internals like the retry subsystem. Prefer the native
12
+ Sidekiq::Worker APIs as some Sidekiq features (e.g. unique jobs) do not work well with AJ.
13
+ (requires Rails 6.0.2)
14
+ ```ruby
15
+ class MyJob < ActiveJob::Base
16
+ queue_as :myqueue
17
+ sidekiq_options retry: 10, backtrace: 20
18
+ def perform(...)
19
+ end
20
+ end
21
+ ```
22
+ - Logging has been redesigned to allow pluggable formatters and several
23
+ formats ship with Sidekiq:
24
+ * default - your typical output on macOS
25
+ * heroku - enabled specifically when running in Heroku
26
+ * json - a JSON format for search indexing, one hash per line
27
+
28
+ Sidekiq will enable the best formatter for the detected environment but
29
+ you can override it by configuring the log formatter explicitly. See
30
+ 'sidekiq/logger' for implementation details.
31
+
32
+ ```ruby
33
+ Sidekiq.configure_server do |config|
34
+ config.log_formatter = AcmeCorp::PlainLogFormatter.new
35
+ # config.log_formatter = Sidekiq::Logger::Formatters::JSON.new
36
+ end
37
+ ```
38
+ Please see the [Logging](https://github.com/mperham/sidekiq/wiki/Logging) wiki page for the latest documentation and notes.
39
+ - **Remove the daemonization, logfile and pidfile command line arguments and `sidekiqctl` binary**.
40
+ I've [noted for years](https://www.mikeperham.com/2014/09/22/dont-daemonize-your-daemons/)
41
+ how modern services should be managed with a proper init system.
42
+ Managing services manually is more error-prone, let your operating system do it for you.
43
+ systemd, upstart, and foreman are three options. See the Deployment wiki page for the latest details.
44
+ - **Validate proper usage of the `REDIS_PROVIDER` variable.**
45
+ This variable is meant to hold the name of the environment
46
+ variable which contains your Redis URL, so that you can switch Redis
47
+ providers quickly and easily with a single variable change. It is not
48
+ meant to hold the actual Redis URL itself. If you want to manually set
49
+ the Redis URL then you may set `REDIS_URL` directly. [#3969]
50
+ - **Increase default shutdown timeout from 8 seconds to 25 seconds.**
51
+ Both Heroku and ECS now use 30 second shutdown timeout
52
+ by default and we want Sidekiq to take advantage of this time. If you
53
+ have deployment scripts which depend on the old default timeout, use `-t 8` to
54
+ get the old behavior. [#3968]
55
+ * **Rails <5** is no longer supported. Rails 6+ only works in zeitwerk mode.
56
+ * **Ruby <2.5** is no longer supported.
57
+ * **Redis <4** is no longer supported.
58
+
59
+ ## Upgrade
60
+
61
+ As always, please upgrade Sidekiq **one major version at a time**.
62
+ If you are already running Sidekiq 5.x, then:
63
+
64
+ * Upgrade to the latest Sidekiq 5.x.
65
+ ```ruby
66
+ gem 'sidekiq', '< 6'
67
+ ```
68
+ * Fix any deprecation warnings you see.
69
+ * Upgrade to 6.x.
70
+ ```ruby
71
+ gem 'sidekiq', '< 7'
72
+ ```
data/Changes.md CHANGED
@@ -2,6 +2,190 @@
2
2
 
3
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
4
 
5
+ 6.1.2
6
+ ---------
7
+
8
+ - Improve readability in dark mode Web UI [#4674]
9
+ - Fix Web UI crash with corrupt session [#4672]
10
+ - Allow middleware to yield arguments [#4673, @eugeneius]
11
+ - Migrate CI from CircleCI to GitHub Actions [#4677]
12
+
13
+ 6.1.1
14
+ ---------
15
+
16
+ - Jobs are now sorted by age in the Busy Workers table. [#4641]
17
+ - Fix "check all" JS logic in Web UI [#4619]
18
+
19
+ 6.1.0
20
+ ---------
21
+
22
+ - Web UI - Dark Mode fixes [#4543, natematykiewicz]
23
+ - Ensure `Rack::ContentLength` is loaded as middleware for correct Web UI responses [#4541]
24
+ - Avoid exception dumping SSL store in Redis connection logging [#4532]
25
+ - Better error messages in Sidekiq::Client [#4549]
26
+ - Remove rack-protection, reimplement CSRF protection [#4588]
27
+ - Require redis-rb 4.2 [#4591]
28
+ - Update to jquery 1.12.4 [#4593]
29
+ - Refactor internal fetch logic and API [#4602]
30
+
31
+ 6.0.7
32
+ ---------
33
+
34
+ - Refactor systemd integration to work better with custom binaries [#4511]
35
+ - Don't connect to Redis at process exit if not needed [#4502]
36
+ - Remove Redis connection naming [#4479]
37
+ - Fix Redis Sentinel password redaction [#4499]
38
+ - Add Vietnamese locale (vi) [#4528]
39
+
40
+ 6.0.6
41
+ ---------
42
+
43
+ - **Integrate with systemd's watchdog and notification features** [#4488]
44
+ Set `Type=notify` in [sidekiq.service](https://github.com/mperham/sidekiq/blob/4b8a8bd3ae42f6e48ae1fdaf95ed7d7af18ed8bb/examples/systemd/sidekiq.service#L30-L39). The integration works automatically.
45
+ - Use `setTimeout` rather than `setInterval` to avoid thundering herd [#4480]
46
+ - Fix edge case where a job can be pushed without a queue.
47
+ - Flush job stats at exit [#4498]
48
+ - Check RAILS_ENV before RACK_ENV [#4493]
49
+ - Add Lithuanian locale [#4476]
50
+
51
+ 6.0.5
52
+ ---------
53
+
54
+ - Fix broken Web UI response when using NewRelic and Rack 2.1.2+. [#4440]
55
+ - Update APIs to use `UNLINK`, not `DEL`. [#4449]
56
+ - Fix Ruby 2.7 warnings [#4412]
57
+ - Add support for `APP_ENV` [[95fa5d9]](https://github.com/mperham/sidekiq/commit/95fa5d90192148026e52ca2902f1b83c70858ce8)
58
+
59
+ 6.0.4
60
+ ---------
61
+
62
+ - Fix ActiveJob's `sidekiq_options` integration [#4404]
63
+ - Sidekiq Pro users will now see a Pause button next to each queue in
64
+ the Web UI, allowing them to pause queues manually [#4374, shayonj]
65
+ - Fix Sidekiq::Workers API unintentional change in 6.0.2 [#4387]
66
+
67
+
68
+ 6.0.3
69
+ ---------
70
+
71
+ - Fix `Sidekiq::Client.push_bulk` API which was erroneously putting
72
+ invalid `at` values in the job payloads [#4321]
73
+
74
+ 6.0.2
75
+ ---------
76
+
77
+ - Fix Sidekiq Enterprise's rolling restart functionality, broken by refactoring in 6.0.0. [#4334]
78
+ - More internal refactoring and performance tuning [fatkodima]
79
+
80
+ 6.0.1
81
+ ---------
82
+
83
+ - **Performance tuning**, Sidekiq should be 10-15% faster now [#4303, 4299,
84
+ 4269, fatkodima]
85
+ - **Dark Mode support in Web UI** (further design polish welcome!) [#4227, mperham,
86
+ fatkodima, silent-e]
87
+ - **Job-specific log levels**, allowing you to turn on debugging for
88
+ problematic workers. [fatkodima, #4287]
89
+ ```ruby
90
+ MyWorker.set(log_level: :debug).perform_async(...)
91
+ ```
92
+ - **Ad-hoc job tags**. You can tag your jobs with, e.g, subdomain, tenant, country,
93
+ locale, application, version, user/client, "alpha/beta/pro/ent", types of jobs,
94
+ teams/people responsible for jobs, additional metadata, etc.
95
+ Tags are shown on different pages with job listings. Sidekiq Pro users
96
+ can filter based on them [fatkodima, #4280]
97
+ ```ruby
98
+ class MyWorker
99
+ include Sidekiq::Worker
100
+ sidekiq_options tags: ['bank-ops', 'alpha']
101
+ ...
102
+ end
103
+ ```
104
+ - Fetch scheduled jobs in batches before pushing into specific queues.
105
+ This will decrease enqueueing time of scheduled jobs by a third. [fatkodima, #4273]
106
+ ```
107
+ ScheduledSet with 10,000 jobs
108
+ Before: 56.6 seconds
109
+ After: 39.2 seconds
110
+ ```
111
+ - Compress error backtraces before pushing into Redis, if you are
112
+ storing error backtraces, this will halve the size of your RetrySet
113
+ in Redis [fatkodima, #4272]
114
+ ```
115
+ RetrySet with 100,000 jobs
116
+ Before: 261 MB
117
+ After: 129 MB
118
+ ```
119
+ - Support display of ActiveJob 6.0 payloads in the Web UI [#4263]
120
+ - Add `SortedSet#scan` for pattern based scanning. For large sets this API will be **MUCH** faster
121
+ than standard iteration using each. [fatkodima, #4262]
122
+ ```ruby
123
+ Sidekiq::DeadSet.new.scan("UnreliableApi") do |job|
124
+ job.retry
125
+ end
126
+ ```
127
+ - Dramatically speed up SortedSet#find\_job(jid) by using Redis's ZSCAN
128
+ support, approx 10x faster. [fatkodima, #4259]
129
+ ```
130
+ zscan 0.179366 0.047727 0.227093 ( 1.161376)
131
+ enum 8.522311 0.419826 8.942137 ( 9.785079)
132
+ ```
133
+ - Respect rails' generators `test_framework` option and gracefully handle extra `worker` suffix on generator [fatkodima, #4256]
134
+ - Add ability to sort 'Enqueued' page on Web UI by position in the queue [fatkodima, #4248]
135
+ - Support `Client.push_bulk` with different delays [fatkodima, #4243]
136
+ ```ruby
137
+ Sidekiq::Client.push_bulk("class" => FooJob, "args" => [[1], [2]], "at" => [1.minute.from_now.to_f, 5.minutes.from_now.to_f])
138
+ ```
139
+ - Easier way to test enqueuing specific ActionMailer and ActiveRecord delayed jobs. Instead of manually
140
+ parsing embedded class, you can now test by fetching jobs for specific classes. [fatkodima, #4292]
141
+ ```ruby
142
+ assert_equal 1, Sidekiq::Extensions::DelayedMailer.jobs_for(FooMailer).size
143
+ ```
144
+ - Add `sidekiqmon` to gemspec executables [#4242]
145
+ - Gracefully handle `Sidekiq.logger = nil` [#4240]
146
+ - Inject Sidekiq::LogContext module if user-supplied logger does not include it [#4239]
147
+
148
+ 6.0
149
+ ---------
150
+
151
+ This release has major breaking changes. Read and test carefully in production.
152
+
153
+ - With Rails 6.0.1+, ActiveJobs can now use `sidekiq_options` directly to configure Sidekiq
154
+ features/internals like the retry subsystem. [#4213, pirj]
155
+ ```ruby
156
+ class MyJob < ActiveJob::Base
157
+ queue_as :myqueue
158
+ sidekiq_options retry: 10, backtrace: 20
159
+ def perform(...)
160
+ end
161
+ end
162
+ ```
163
+ - Logging has been redesigned to allow for pluggable log formatters:
164
+ ```ruby
165
+ Sidekiq.configure_server do |config|
166
+ config.log_formatter = Sidekiq::Logger::Formatters::JSON.new
167
+ end
168
+ ```
169
+ See the [Logging wiki page](https://github.com/mperham/sidekiq/wiki/Logging) for more details.
170
+ - **BREAKING CHANGE** Validate proper usage of the `REDIS_PROVIDER`
171
+ variable. This variable is meant to hold the name of the environment
172
+ variable which contains your Redis URL, so that you can switch Redis
173
+ providers quickly and easily with a single variable change. It is not
174
+ meant to hold the actual Redis URL itself. If you want to manually set
175
+ the Redis URL (not recommended as it implies you have no failover),
176
+ then you may set `REDIS_URL` directly. [#3969]
177
+ - **BREAKING CHANGE** Increase default shutdown timeout from 8 seconds
178
+ to 25 seconds. Both Heroku and ECS now use 30 second shutdown timeout
179
+ by default and we want Sidekiq to take advantage of this time. If you
180
+ have deployment scripts which depend on the old default timeout, use `-t 8` to
181
+ get the old behavior. [#3968]
182
+ - **BREAKING CHANGE** Remove the daemonization, logfile and pidfile
183
+ arguments to Sidekiq. Use a proper process supervisor (e.g. systemd or
184
+ foreman) to manage Sidekiq. See the Deployment wiki page for links to
185
+ more resources.
186
+ - Integrate the StandardRB code formatter to ensure consistent code
187
+ styling. [#4114, gearnode]
188
+
5
189
  5.2.9
6
190
  ---------
7
191
 
@@ -0,0 +1,37 @@
1
+ # Welcome to Sidekiq Enterprise 2.0!
2
+
3
+ Sidekiq Enterprise 2.0 adds a few new features and adds the requirement that license
4
+ credentials be available at runtime. Note that Sidekiq 6.0 does have major breaking changes.
5
+
6
+ ## What's New
7
+
8
+ * Sidekiq Enterprise now requires license credentials at runtime. If you
9
+ configured Bundler as described in the access email you need do
10
+ nothing, everything should just work. If you are vendoring Sidekiq
11
+ Enterprise you will need to configure Bundler also or set
12
+ `SIDEKIQ_ENT_USERNAME=abcdef12 bundle exec sidekiq...` when starting the
13
+ process. [#4232]
14
+ * Dead jobs now release any unique locks they were holding when they died [#4162]
15
+ * Backoff can now be customized per rate limiter by passing in a Proc [#4219]
16
+ ```ruby
17
+ limiter = Sidekiq::Limiter.bucket(:stripe, 10, :second, backoff: ->(limiter, job) {
18
+ return job['overrated'] || 5 # wait for N seconds, where N is the number of
19
+ # times we've failed the rate limit
20
+ })
21
+ ```
22
+ * Removed deprecated APIs and warnings.
23
+ * Various changes for Sidekiq 6.0
24
+ * Requires Ruby 2.5+ and Redis 4.0+
25
+ * Requires Sidekiq 6.0+ and Sidekiq Pro 5.0+
26
+
27
+ ## Upgrade
28
+
29
+ * Upgrade to the latest Sidekiq Enterprise 1.x.
30
+ ```ruby
31
+ gem 'sidekiq-ent', '< 2'
32
+ ```
33
+ * Fix any deprecation warnings you see.
34
+ * Upgrade to 2.x.
35
+ ```ruby
36
+ gem 'sidekiq-ent', '< 3'
37
+ ```
data/Ent-Changes.md CHANGED
@@ -2,7 +2,50 @@
2
2
 
3
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
4
 
5
- Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how to buy.
5
+ Please see [sidekiq.org](https://sidekiq.org) for more details and how to buy.
6
+
7
+ 2.1.2
8
+ -------------
9
+
10
+ - The Sidekiq Pro and Enterprise gem servers now `bundle install` much faster with **Bundler 2.2+** [#4158]
11
+ - Now that ActiveJobs support `sidekiq_options`, add support for uniqueness in AJs [#4667]
12
+
13
+ 2.1.1
14
+ -------------
15
+
16
+ - Add optional **app preload** in swarm, saves even more memory [#4646]
17
+ - Fix incorrect queue tags in historical metrics [#4377]
18
+
19
+ 2.1.0
20
+ -------------
21
+
22
+ - Move historical metrics to use tags rather than interpolating name [#4377]
23
+ ```
24
+ sidekiq.enqueued.#{name} -> sidekiq.queue.size with tag queue:#{name}
25
+ sidekiq.latency.#{name} -> sidekiq.queue.latency with tag queue:#{name}
26
+ ```
27
+ - Remove `concurrent-ruby` gem dependency [#4586]
28
+ - Add systemd `Type=notify` support for swarm [#4511]
29
+ - Length swarm's boot timeout to 60 sec [#4544]
30
+ - Add NL locale
31
+
32
+ 2.0.1
33
+ -------------
34
+
35
+ - Periodic job registration API adjusted to avoid loading classes in initializer [#4271]
36
+ - Remove support for deprecated ENV variables (COUNT, MAXMEM\_MB, INDEX) in swarm code
37
+
38
+ 2.0.0
39
+ -------------
40
+
41
+ - Except for the [newly required credentials](https://github.com/mperham/sidekiq/issues/4232), Sidekiq Enterprise 2.0 does
42
+ not have any significant migration steps.
43
+ - Sidekiq Enterprise must now be started with valid license credentials. [#4232]
44
+ - Call `GC.compact` if possible in sidekiqswarm before forking [#4181]
45
+ - Changes for forward-compatibility with Sidekiq 6.0.
46
+ - Add death handler to remove any lingering unique locks [#4162]
47
+ - Backoff can now be customized per rate limiter [#4219]
48
+ - Code formatting changes for StandardRB
6
49
 
7
50
  1.8.1
8
51
  -------------
data/Gemfile CHANGED
@@ -1,23 +1,24 @@
1
- source 'https://rubygems.org'
1
+ source "https://rubygems.org"
2
2
 
3
3
  gemspec
4
4
 
5
- gem 'rake'
6
- gem 'redis-namespace'
7
- gem 'rails', '~> 5.2'
8
- gem 'sqlite3', '~> 1.3.6', platforms: :ruby
9
- gem 'activerecord-jdbcsqlite3-adapter', platforms: :jruby
5
+ gem "rake"
6
+ gem "redis-namespace"
7
+ gem "rails", ">= 6.0.2"
8
+ gem "sqlite3", platforms: :ruby
9
+ gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
10
10
 
11
11
  group :test do
12
- gem 'minitest'
13
- gem 'simplecov'
12
+ gem "minitest"
13
+ gem "simplecov"
14
+ gem "codecov", require: false
14
15
  end
15
16
 
16
17
  group :development, :test do
17
- gem 'pry-byebug', platforms: :mri
18
+ gem "standard"
18
19
  end
19
20
 
20
21
  group :load_test do
21
- gem 'hiredis'
22
- gem 'toxiproxy'
22
+ gem "hiredis"
23
+ gem "toxiproxy"
23
24
  end
data/Gemfile.lock ADDED
@@ -0,0 +1,192 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ sidekiq (6.1.2)
5
+ connection_pool (>= 2.2.2)
6
+ rack (~> 2.0)
7
+ redis (>= 4.2.0)
8
+
9
+ GEM
10
+ remote: https://rubygems.org/
11
+ specs:
12
+ actioncable (6.0.3.2)
13
+ actionpack (= 6.0.3.2)
14
+ nio4r (~> 2.0)
15
+ websocket-driver (>= 0.6.1)
16
+ actionmailbox (6.0.3.2)
17
+ actionpack (= 6.0.3.2)
18
+ activejob (= 6.0.3.2)
19
+ activerecord (= 6.0.3.2)
20
+ activestorage (= 6.0.3.2)
21
+ activesupport (= 6.0.3.2)
22
+ mail (>= 2.7.1)
23
+ actionmailer (6.0.3.2)
24
+ actionpack (= 6.0.3.2)
25
+ actionview (= 6.0.3.2)
26
+ activejob (= 6.0.3.2)
27
+ mail (~> 2.5, >= 2.5.4)
28
+ rails-dom-testing (~> 2.0)
29
+ actionpack (6.0.3.2)
30
+ actionview (= 6.0.3.2)
31
+ activesupport (= 6.0.3.2)
32
+ rack (~> 2.0, >= 2.0.8)
33
+ rack-test (>= 0.6.3)
34
+ rails-dom-testing (~> 2.0)
35
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
36
+ actiontext (6.0.3.2)
37
+ actionpack (= 6.0.3.2)
38
+ activerecord (= 6.0.3.2)
39
+ activestorage (= 6.0.3.2)
40
+ activesupport (= 6.0.3.2)
41
+ nokogiri (>= 1.8.5)
42
+ actionview (6.0.3.2)
43
+ activesupport (= 6.0.3.2)
44
+ builder (~> 3.1)
45
+ erubi (~> 1.4)
46
+ rails-dom-testing (~> 2.0)
47
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
48
+ activejob (6.0.3.2)
49
+ activesupport (= 6.0.3.2)
50
+ globalid (>= 0.3.6)
51
+ activemodel (6.0.3.2)
52
+ activesupport (= 6.0.3.2)
53
+ activerecord (6.0.3.2)
54
+ activemodel (= 6.0.3.2)
55
+ activesupport (= 6.0.3.2)
56
+ activestorage (6.0.3.2)
57
+ actionpack (= 6.0.3.2)
58
+ activejob (= 6.0.3.2)
59
+ activerecord (= 6.0.3.2)
60
+ marcel (~> 0.3.1)
61
+ activesupport (6.0.3.2)
62
+ concurrent-ruby (~> 1.0, >= 1.0.2)
63
+ i18n (>= 0.7, < 2)
64
+ minitest (~> 5.1)
65
+ tzinfo (~> 1.1)
66
+ zeitwerk (~> 2.2, >= 2.2.2)
67
+ ast (2.4.1)
68
+ builder (3.2.4)
69
+ codecov (0.2.8)
70
+ json
71
+ simplecov
72
+ concurrent-ruby (1.1.7)
73
+ connection_pool (2.2.3)
74
+ crass (1.0.6)
75
+ docile (1.3.2)
76
+ erubi (1.9.0)
77
+ globalid (0.4.2)
78
+ activesupport (>= 4.2.0)
79
+ hiredis (0.6.3)
80
+ i18n (1.8.5)
81
+ concurrent-ruby (~> 1.0)
82
+ json (2.3.1)
83
+ loofah (2.7.0)
84
+ crass (~> 1.0.2)
85
+ nokogiri (>= 1.5.9)
86
+ mail (2.7.1)
87
+ mini_mime (>= 0.1.1)
88
+ marcel (0.3.3)
89
+ mimemagic (~> 0.3.2)
90
+ method_source (1.0.0)
91
+ mimemagic (0.3.5)
92
+ mini_mime (1.0.2)
93
+ mini_portile2 (2.4.0)
94
+ minitest (5.14.1)
95
+ nio4r (2.5.2)
96
+ nokogiri (1.10.10)
97
+ mini_portile2 (~> 2.4.0)
98
+ parallel (1.19.2)
99
+ parser (2.7.1.4)
100
+ ast (~> 2.4.1)
101
+ rack (2.2.3)
102
+ rack-test (1.1.0)
103
+ rack (>= 1.0, < 3)
104
+ rails (6.0.3.2)
105
+ actioncable (= 6.0.3.2)
106
+ actionmailbox (= 6.0.3.2)
107
+ actionmailer (= 6.0.3.2)
108
+ actionpack (= 6.0.3.2)
109
+ actiontext (= 6.0.3.2)
110
+ actionview (= 6.0.3.2)
111
+ activejob (= 6.0.3.2)
112
+ activemodel (= 6.0.3.2)
113
+ activerecord (= 6.0.3.2)
114
+ activestorage (= 6.0.3.2)
115
+ activesupport (= 6.0.3.2)
116
+ bundler (>= 1.3.0)
117
+ railties (= 6.0.3.2)
118
+ sprockets-rails (>= 2.0.0)
119
+ rails-dom-testing (2.0.3)
120
+ activesupport (>= 4.2.0)
121
+ nokogiri (>= 1.6)
122
+ rails-html-sanitizer (1.3.0)
123
+ loofah (~> 2.3)
124
+ railties (6.0.3.2)
125
+ actionpack (= 6.0.3.2)
126
+ activesupport (= 6.0.3.2)
127
+ method_source
128
+ rake (>= 0.8.7)
129
+ thor (>= 0.20.3, < 2.0)
130
+ rainbow (3.0.0)
131
+ rake (13.0.1)
132
+ redis (4.2.1)
133
+ redis-namespace (1.8.0)
134
+ redis (>= 3.0.4)
135
+ regexp_parser (1.7.1)
136
+ rexml (3.2.4)
137
+ rubocop (0.89.1)
138
+ parallel (~> 1.10)
139
+ parser (>= 2.7.1.1)
140
+ rainbow (>= 2.2.2, < 4.0)
141
+ regexp_parser (>= 1.7)
142
+ rexml
143
+ rubocop-ast (>= 0.3.0, < 1.0)
144
+ ruby-progressbar (~> 1.7)
145
+ unicode-display_width (>= 1.4.0, < 2.0)
146
+ rubocop-ast (0.3.0)
147
+ parser (>= 2.7.1.4)
148
+ rubocop-performance (1.7.1)
149
+ rubocop (>= 0.82.0)
150
+ ruby-progressbar (1.10.1)
151
+ simplecov (0.19.0)
152
+ docile (~> 1.1)
153
+ simplecov-html (~> 0.11)
154
+ simplecov-html (0.12.2)
155
+ sprockets (4.0.2)
156
+ concurrent-ruby (~> 1.0)
157
+ rack (> 1, < 3)
158
+ sprockets-rails (3.2.1)
159
+ actionpack (>= 4.0)
160
+ activesupport (>= 4.0)
161
+ sprockets (>= 3.0.0)
162
+ sqlite3 (1.4.2)
163
+ standard (0.5.2)
164
+ rubocop (~> 0.89.1)
165
+ rubocop-performance (~> 1.7.1)
166
+ thor (1.0.1)
167
+ thread_safe (0.3.6)
168
+ toxiproxy (1.0.3)
169
+ tzinfo (1.2.7)
170
+ thread_safe (~> 0.1)
171
+ unicode-display_width (1.7.0)
172
+ websocket-driver (0.7.3)
173
+ websocket-extensions (>= 0.1.0)
174
+ websocket-extensions (0.1.5)
175
+ zeitwerk (2.4.0)
176
+
177
+ PLATFORMS
178
+ ruby
179
+
180
+ DEPENDENCIES
181
+ activerecord-jdbcsqlite3-adapter
182
+ codecov
183
+ hiredis
184
+ minitest
185
+ rails (>= 6.0.2)
186
+ rake
187
+ redis-namespace
188
+ sidekiq!
189
+ simplecov
190
+ sqlite3
191
+ standard
192
+ toxiproxy