sidekiq 5.2.5 → 6.0.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 (79) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +82 -0
  3. data/.gitignore +0 -2
  4. data/.standard.yml +20 -0
  5. data/6.0-Upgrade.md +72 -0
  6. data/COMM-LICENSE +11 -9
  7. data/Changes.md +130 -0
  8. data/Ent-2.0-Upgrade.md +37 -0
  9. data/Ent-Changes.md +32 -1
  10. data/Gemfile +12 -17
  11. data/Gemfile.lock +196 -0
  12. data/Pro-5.0-Upgrade.md +25 -0
  13. data/Pro-Changes.md +26 -2
  14. data/README.md +19 -31
  15. data/Rakefile +5 -4
  16. data/bin/sidekiqload +33 -25
  17. data/bin/sidekiqmon +8 -0
  18. data/lib/generators/sidekiq/templates/worker_test.rb.erb +1 -1
  19. data/lib/generators/sidekiq/worker_generator.rb +20 -12
  20. data/lib/sidekiq.rb +61 -42
  21. data/lib/sidekiq/api.rb +220 -192
  22. data/lib/sidekiq/cli.rb +111 -174
  23. data/lib/sidekiq/client.rb +51 -46
  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 +10 -20
  27. data/lib/sidekiq/extensions/active_record.rb +9 -7
  28. data/lib/sidekiq/extensions/class_methods.rb +9 -7
  29. data/lib/sidekiq/extensions/generic_proxy.rb +4 -4
  30. data/lib/sidekiq/fetch.rb +11 -12
  31. data/lib/sidekiq/job_logger.rb +45 -7
  32. data/lib/sidekiq/job_retry.rb +71 -60
  33. data/lib/sidekiq/launcher.rb +57 -51
  34. data/lib/sidekiq/logger.rb +165 -0
  35. data/lib/sidekiq/manager.rb +7 -9
  36. data/lib/sidekiq/middleware/chain.rb +14 -4
  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 +83 -75
  41. data/lib/sidekiq/rails.rb +23 -29
  42. data/lib/sidekiq/redis_connection.rb +31 -37
  43. data/lib/sidekiq/scheduled.rb +28 -29
  44. data/lib/sidekiq/testing.rb +34 -23
  45. data/lib/sidekiq/testing/inline.rb +2 -1
  46. data/lib/sidekiq/util.rb +17 -16
  47. data/lib/sidekiq/version.rb +2 -1
  48. data/lib/sidekiq/web.rb +41 -49
  49. data/lib/sidekiq/web/action.rb +14 -10
  50. data/lib/sidekiq/web/application.rb +64 -66
  51. data/lib/sidekiq/web/helpers.rb +89 -71
  52. data/lib/sidekiq/web/router.rb +17 -14
  53. data/lib/sidekiq/worker.rb +129 -97
  54. data/sidekiq.gemspec +16 -16
  55. data/web/assets/javascripts/dashboard.js +4 -23
  56. data/web/assets/stylesheets/application-dark.css +125 -0
  57. data/web/assets/stylesheets/application.css +9 -0
  58. data/web/assets/stylesheets/bootstrap.css +1 -1
  59. data/web/locales/de.yml +14 -2
  60. data/web/locales/ja.yml +2 -1
  61. data/web/views/_job_info.erb +2 -1
  62. data/web/views/busy.erb +4 -1
  63. data/web/views/dead.erb +2 -2
  64. data/web/views/layout.erb +1 -0
  65. data/web/views/morgue.erb +4 -1
  66. data/web/views/queue.erb +10 -1
  67. data/web/views/queues.erb +1 -1
  68. data/web/views/retries.erb +4 -1
  69. data/web/views/retry.erb +2 -2
  70. data/web/views/scheduled.erb +4 -1
  71. metadata +21 -32
  72. data/.travis.yml +0 -17
  73. data/Appraisals +0 -9
  74. data/bin/sidekiqctl +0 -237
  75. data/gemfiles/rails_4.gemfile +0 -31
  76. data/gemfiles/rails_5.gemfile +0 -31
  77. data/lib/sidekiq/core_ext.rb +0 -1
  78. data/lib/sidekiq/logging.rb +0 -122
  79. 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: e05ebe69a6d3d12f50f741e147e413b78dbc24038f8a22bf5bbdff8cd4a1f1a0
4
- data.tar.gz: 45b1a5cdc5bc79fbe35599d6e5942c21590fea0b88d9b5adc8ae3ddc767f65eb
3
+ metadata.gz: 9dd138f78183ff31972192acbcee3ea7aad67403dfdd478500f3bbbfebf14698
4
+ data.tar.gz: ea4ab3b7c40bf358a80df9043013a63ee7c0562322ce5f212f938cecdc93c62f
5
5
  SHA512:
6
- metadata.gz: f582228b5f93aae8c5ba2cc9297f235d420e15fa04cfcffafd60852274e685a1a75809e6f8b24ab00f0ce375faa718fc68d37cb866bd21f291ca11319c895dfe
7
- data.tar.gz: fd5790b633e36125a9cdcf3850e6dc9b87872b47899bd3375b89cdf13197951948b1586ba96b0a051f4cb34b8f28d93a3121cd747d01820a14b2ad6192fd89df
6
+ metadata.gz: c34d01bffdf5af462b98afa03e4b71356b8afffd873533eb953305314e1c0fd0ea4a4c0eea53c7169b61aca51420a50d5eda9127ad815c46c4053954677be24d
7
+ data.tar.gz: fdfe2b1704bc7d3a071756ca983c9b81bf4534ceb5f532bec59ec87fe4c3094c95120a7b1471163327f55e132c9773a3fd05d9a6211c6c1a1342c58872e8d980
@@ -0,0 +1,82 @@
1
+ version: 2
2
+ references:
3
+ unit: &unit
4
+ run:
5
+ name: Run test suite
6
+ command: bundle exec rake
7
+ restore: &restore
8
+ restore_cache:
9
+ keys:
10
+ - v1-dependencies-{{ checksum "Gemfile.lock" }}
11
+ # fallback to using the latest cache if no exact match is found
12
+ - v1-dependencies-
13
+ bundle: &bundle
14
+ run:
15
+ name: install dependencies
16
+ command: |
17
+ bundle install --jobs=4 --retry=3 --path vendor/bundle
18
+ save: &save
19
+ save_cache:
20
+ paths:
21
+ - ./vendor/bundle
22
+ key: v1-dependencies-{{ checksum "Gemfile.lock" }}
23
+ jobs:
24
+ "ruby-2.5":
25
+ docker:
26
+ - image: circleci/ruby:2.5
27
+ - image: circleci/redis:4.0
28
+ steps:
29
+ - checkout
30
+ - <<: *restore
31
+ - <<: *bundle
32
+ - <<: *save
33
+ - <<: *unit
34
+ "ruby-2.6":
35
+ environment:
36
+ COVERAGE: true
37
+ CC_TEST_REPORTER_ID: 003c3033501d70a2653bd887ff9a8b2884a263e6a4e27f2ba68748e15530918d
38
+ docker:
39
+ - image: circleci/ruby:2.6
40
+ - image: circleci/redis:4.0
41
+ steps:
42
+ - checkout
43
+ - <<: *restore
44
+ - <<: *bundle
45
+ - <<: *save
46
+
47
+ - run:
48
+ name: Setup Code Climate test-reporter
49
+ command: |
50
+ # download test reporter as a static binary
51
+ curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
52
+ chmod +x ./cc-test-reporter
53
+
54
+ - run:
55
+ name: Code Climate before-build
56
+ command: |
57
+ ./cc-test-reporter before-build
58
+
59
+ - <<: *unit
60
+
61
+ - run:
62
+ name: Report code coverage to Code Climate
63
+ command: |
64
+ ./cc-test-reporter after-build -t simplecov --exit-code $?
65
+ "jruby":
66
+ docker:
67
+ - image: circleci/jruby:latest
68
+ - image: circleci/redis:4.0
69
+ steps:
70
+ - checkout
71
+ - <<: *restore
72
+ - <<: *bundle
73
+ - <<: *save
74
+ - <<: *unit
75
+
76
+ workflows:
77
+ version: 2
78
+ build:
79
+ jobs:
80
+ - "ruby-2.5"
81
+ - "ruby-2.6"
82
+ - "jruby"
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
@@ -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
@@ -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.1)
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
+ ```
@@ -14,13 +14,15 @@ In order to use the Software under this Agreement, you must receive a “Source
14
14
 
15
15
  1.2 Unlimited Organization License. If you purchased an Organization License (included with the Sidekiq Pro Software), you may install the Software on an unlimited number of Hosts. “Host” means any physical or virtual machine which is controlled by you. You may also run an unlimited number of Workers. “Worker” means a thread within a Sidekiq server process which executes jobs. You may concurrently run the software on an unlimited number of Hosts, with each host running an unlimited number of Workers.
16
16
 
17
- 1.3 Limited Organization License. If you purchased an Organization License (included with the Sidekiq Enterprise Software), you may install the Software on an unlimited number of Hosts. “Host” means any physical or virtual machine which is controlled by you. The aggregate number of Workers run by the hosts must not exceed the maximum number of Workers authorized at the time of purchase. “Worker” means a thread within a Sidekiq server process which executes jobs. In order to run additional Workers, you must purchase an additional allowance from Contributed Systems.
17
+ 1.3 Limited Enterprise License. If you purchased a Limited License for the Sidekiq Enterprise Software, you may install the Software on an unlimited number of Hosts. “Host” means any physical or virtual machine which is controlled by you. The aggregate number of Workers run by the hosts must not exceed the maximum number of Workers authorized at the time of purchase. “Worker” means a thread within a Sidekiq server process which executes jobs. In order to run additional Workers, you must purchase an additional allowance from Contributed Systems.
18
18
 
19
- 1.4 Appliance License. If you purchased an Appliance License, you may distribute the Software in any applications, frameworks, or elements (collectively referred to as an “Application” or “Applications”) that you develop using the Software in accordance with this EULA, provided that such distribution does not violate the restrictions set forth in section 3 of this EULA. You must not remove, obscure or interfere with any copyright, acknowledgment, attribution, trademark, warning or disclaimer statement affixed to, incorporated in or otherwise applied in connection with the Software. You are required to ensure that the Software is not reused by or with any applications other than those with which you distribute it as permitted herein. For example, if You install the Software on a customer’s server, that customer is not permitted to use the Software independently of your Application. You must inform Contributed Systems of your knowledge of any infringing use of the Software by any of your customers. You are liable for compliance by those third parties with the terms and conditions of this EULA. You will not owe Contributed Systems any royalties for your distribution of the Software in accordance with this EULA.
19
+ 1.4 Enterprise Site License. If you purchased a Site License for the Sidekiq Enterprise Software, you may install the Software on an unlimited number of Hosts. “Host” means any physical or virtual machine which is controlled by you. You may also run an unlimited number of Workers. “Worker” means a thread within a Sidekiq server process which executes jobs. You may concurrently run the software on an unlimited number of Hosts, with each host running an unlimited number of Workers.
20
20
 
21
- 1.5 Archive Copies. You are entitled to make a reasonable amount of copies of the Software for archival purposes. Each copy must reproduce all copyright and other proprietary rights notices on or in the Software Product.
21
+ 1.5 Appliance License. If you purchased an Appliance License, you may distribute the Software in any applications, frameworks, or elements (collectively referred to as an “Application” or “Applications”) that you develop using the Software in accordance with this EULA, provided that such distribution does not violate the restrictions set forth in section 3 of this EULA. You must not remove, obscure or interfere with any copyright, acknowledgment, attribution, trademark, warning or disclaimer statement affixed to, incorporated in or otherwise applied in connection with the Software. You are required to ensure that the Software is not reused by or with any applications other than those with which you distribute it as permitted herein. For example, if You install the Software on a customer's server, that customer is not permitted to use the Software independently of your Application. You must inform Contributed Systems of your knowledge of any infringing use of the Software by any of your customers. You are liable for compliance by those third parties with the terms and conditions of this EULA. You will not owe Contributed Systems any royalties for your distribution of the Software in accordance with this EULA.
22
22
 
23
- 1.6 Electronic Delivery. All Software and license documentation shall be delivered by electronic means unless otherwise specified on the applicable invoice or at the time of purchase. Software shall be deemed delivered when it is made available for download by you (“Delivery”).
23
+ 1.6 Archive Copies. You are entitled to make a reasonable amount of copies of the Software for archival purposes. Each copy must reproduce all copyright and other proprietary rights notices on or in the Software Product.
24
+
25
+ 1.7 Electronic Delivery. All Software and license documentation shall be delivered by electronic means unless otherwise specified on the applicable invoice or at the time of purchase. Software shall be deemed delivered when it is made available for download by you (“Delivery”).
24
26
 
25
27
  2. Modifications. Contributed Systems shall provide you with source code so that you can create Modifications of the original software. “Modification” means: (a) any addition to or deletion from the contents of a file included in the original Software or previous Modifications created by You, or (b) any new file that contains any part of the original Software or previous Modifications. While you retain all rights to any original work authored by you as part of the Modifications, We continue to own all copyright and other intellectual property rights in the Software.
26
28
 
@@ -31,7 +33,7 @@ In order to use the Software under this Agreement, you must receive a “Source
31
33
  3.2 UNDER NO CIRCUMSTANCES MAY YOU USE THE SOFTWARE AS PART OF A PRODUCT OR SERVICE THAT PROVIDES SIMILAR FUNCTIONALITY TO THE SOFTWARE ITSELF.
32
34
 
33
35
  The Open Source version of the Software (“LGPL Version”) is licensed
34
- under the terms of the GNU Lesser General Public License versions 3.0
36
+ under the terms of the GNU Lesser General Public License version 3.0
35
37
  (“LGPL”) and not under this EULA.
36
38
 
37
39
  4. Ownership. Notwithstanding anything to the contrary contained herein, except for the limited license rights expressly provided herein, Contributed Systems and its suppliers have and will retain all rights, title and interest (including, without limitation, all patent, copyright, trademark, trade secret and other intellectual property rights) in and to the Software and all copies, modifications and derivative works thereof (including any changes which incorporate any of your ideas, feedback or suggestions). You acknowledge that you are obtaining only a limited license right to the Software, and that irrespective of any use of the words “purchase”, “sale” or like terms hereunder no ownership rights are being conveyed to you under this Agreement or otherwise.
@@ -42,7 +44,7 @@ under the terms of the GNU Lesser General Public License versions 3.0
42
44
 
43
45
  7. Term of Agreement.
44
46
 
45
- 7.1 Term. This Agreement is effective as of the Delivery of the Software and expires at such time as all license and service subscriptions hereunder have expired in accordance with their own terms (the “Term”). For clarification, the term of your license under this Agreement may be perpetual, limited for Evaluation Version, or designated as a fixed-term license in the Invoice, and shall be specified at your time of purchase. Either party may terminate this Agreement (including all related Invoices) if the other party: (a) fails to cure any material breach of this Agreement within thirty (30) days after written notice of such breach, provided that Contributed Systems may terminate this Agreement immediately upon any breach of Section 3 or if you exceed any other restrictions contained in Section 1, unless otherwise specified in this agreement; (b) ceases operation without a successor; or (c) seeks protection under any bankruptcy, receivership, trust deed, creditors arrangement, composition or comparable proceeding, or if any such proceeding is instituted against such party (and not dismissed within sixty (60) days)). Termination is not an exclusive remedy and the exercise by either party of any remedy under this Agreement will be without prejudice to any other remedies it may have under this Agreement, by law, or otherwise.
47
+ 7.1 Term. This Agreement is effective as of the Delivery of the Software and expires at such time as all license and service subscriptions hereunder have expired in accordance with their own terms (the “Term”). For clarification, the term of your license under this Agreement may be perpetual, limited for Evaluation Version, or designated as a fixed-term license in the Invoice, and shall be specified at your time of purchase. Either party may terminate this Agreement (including all related Invoices) if the other party: (a) fails to cure any material breach of this Agreement within thirty (30) days after written notice of such breach, provided that Contributed Systems may terminate this Agreement immediately upon any breach of Section 3 or if you exceed any other restrictions contained in Section 1, unless otherwise specified in this agreement; (b) ceases operation without a successor; or (c) seeks protection under any bankruptcy, receivership, trust deed, creditors arrangement, composition or comparable proceeding, or if any such proceeding is instituted against such party (and not dismissed within sixty (60) days)). Termination is not an exclusive remedy and the exercise by either party of any remedy under this Agreement will be without prejudice to any other remedies it may have under this Agreement, by law, or otherwise.
46
48
 
47
49
  7.2 Termination. Upon any termination of this Agreement, you shall cease any and all use of any Software and destroy all copies thereof.
48
50
 
@@ -57,7 +59,7 @@ In no event will Contributed Systems be liable for any direct, indirect, consequ
57
59
 
58
60
  In no event will Contributed Systems' liability exceed the Software license price as indicated in the invoice. The existence of more than one claim will not enlarge or extend this limit.
59
61
 
60
- 10. Remedies. Your exclusive remedy and Contributed Systems entire liability for breach of this Agreement shall be limited, at Contributed Systems sole and exclusive discretion, to (a) replacement of any defective software or documentation; or (b) refund of the license fee paid to Contributed Systems, payable in accordance with Contributed Systems' refund policy.
62
+ 10. Remedies. Your exclusive remedy and Contributed Systems' entire liability for breach of this Agreement shall be limited, at Contributed Systems' sole and exclusive discretion, to (a) replacement of any defective software or documentation; or (b) refund of the license fee paid to Contributed Systems, payable in accordance with Contributed Systems' refund policy.
61
63
 
62
64
  11. Acknowledgements.
63
65
 
@@ -67,7 +69,7 @@ In no event will Contributed Systems' liability exceed the Software license pric
67
69
 
68
70
  11.3 Government End Users. If the Software and related documentation are supplied to or purchased by or on behalf of the United States Government, then the Software is deemed to be "commercial software" as that term is used in the Federal Acquisition Regulation system. Rights of the United States shall not exceed the minimum rights set forth in FAR 52.227-19 for "restricted computer software". All other terms and conditions of this Agreement apply.
69
71
 
70
- 12. Third Party Software. Examples included in Software may provide links to third party libraries or code (collectively “Third Party Software”) to implement various functions. Third Party Software does not comprise part of the Software. In some cases, access to Third Party Software may be included along with the Software delivery as a convenience for demonstration purposes. Such source code and libraries may be included in the “…/examples” source tree delivered with the Software and do not comprise the Software. Licensee acknowledges (1) that some part of Third Party Software may require additional licensing of copyright and patents from the owners of such, and (2) that distribution of any of the Software referencing or including any portion of a Third Party Software may require appropriate licensing from such third parties.
72
+ 12. Third Party Software. Examples included in Software may provide links to third party libraries or code (collectively “Third Party Software”) to implement various functions. Third Party Software does not comprise part of the Software. In some cases, access to Third Party Software may be included along with the Software delivery as a convenience for demonstration purposes. Such source code and libraries may be included in the “…/examples” source tree delivered with the Software and do not comprise the Software. Licensee acknowledges (1) that some part of Third Party Software may require additional licensing of copyright and patents from the owners of such, and (2) that distribution of any of the Software referencing or including any portion of a Third Party Software may require appropriate licensing from such third parties.
71
73
 
72
74
 
73
75
  13. Miscellaneous
@@ -84,7 +86,7 @@ In no event will Contributed Systems' liability exceed the Software license pric
84
86
 
85
87
  13.6 Governing Law. This Agreement is governed by the laws of the State of Oregon and the United States without regard to conflicts of laws provisions thereof, and without regard to the United Nations Convention on the International Sale of Goods or the Uniform Computer Information Transactions Act, as currently enacted by any jurisdiction or as may be codified or amended from time to time by any jurisdiction. The jurisdiction and venue for actions related to the subject matter hereof shall be the state of Oregon and United States federal courts located in Portland, Oregon, and both parties hereby submit to the personal jurisdiction of such courts.
86
88
 
87
- 13.7 Attorneys Fees and Costs. The prevailing party in any action to enforce this Agreement will be entitled to recover its attorneys fees and costs in connection with such action.
89
+ 13.7 Attorneys' Fees and Costs. The prevailing party in any action to enforce this Agreement will be entitled to recover its attorneys' fees and costs in connection with such action.
88
90
 
89
91
  13.8 Severability. If any provision of this Agreement is held by a court of competent jurisdiction to be invalid, illegal, or unenforceable, the remainder of this Agreement will remain in full force and effect.
90
92
 
data/Changes.md CHANGED
@@ -2,6 +2,136 @@
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.0.2
6
+ ---------
7
+
8
+ - Fix Sidekiq Enterprise's rolling restart functionality, broken by refactoring in 6.0.0. [#4334]
9
+ - More internal refactoring and performance tuning [fatkodima]
10
+
11
+ 6.0.1
12
+ ---------
13
+
14
+ - **Performance tuning**, Sidekiq should be 10-15% faster now [#4303, 4299,
15
+ 4269, fatkodima]
16
+ - **Dark Mode support in Web UI** (further design polish welcome!) [#4227, mperham,
17
+ fatkodima, silent-e]
18
+ - **Job-specific log levels**, allowing you to turn on debugging for
19
+ problematic workers. [fatkodima, #4287]
20
+ ```ruby
21
+ MyWorker.set(log_level: :debug).perform_async(...)
22
+ ```
23
+ - **Ad-hoc job tags**. You can tag your jobs with, e.g, subdomain, tenant, country,
24
+ locale, application, version, user/client, "alpha/beta/pro/ent", types of jobs,
25
+ teams/people responsible for jobs, additional metadata, etc.
26
+ Tags are shown on different pages with job listings. Sidekiq Pro users
27
+ can filter based on them [fatkodima, #4280]
28
+ ```ruby
29
+ class MyWorker
30
+ include Sidekiq::Worker
31
+ sidekiq_options tags: ['bank-ops', 'alpha']
32
+ ...
33
+ end
34
+ ```
35
+ - Fetch scheduled jobs in batches before pushing into specific queues.
36
+ This will decrease enqueueing time of scheduled jobs by a third. [fatkodima, #4273]
37
+ ```
38
+ ScheduledSet with 10,000 jobs
39
+ Before: 56.6 seconds
40
+ After: 39.2 seconds
41
+ ```
42
+ - Compress error backtraces before pushing into Redis, if you are
43
+ storing error backtraces, this will halve the size of your RetrySet
44
+ in Redis [fatkodima, #4272]
45
+ ```
46
+ RetrySet with 100,000 jobs
47
+ Before: 261 MB
48
+ After: 129 MB
49
+ ```
50
+ - Support display of ActiveJob 6.0 payloads in the Web UI [#4263]
51
+ - Add `SortedSet#scan` for pattern based scanning. For large sets this API will be **MUCH** faster
52
+ than standard iteration using each. [fatkodima, #4262]
53
+ ```ruby
54
+ Sidekiq::DeadSet.new.scan("UnreliableApi") do |job|
55
+ job.retry
56
+ end
57
+ ```
58
+ - Dramatically speed up SortedSet#find\_job(jid) by using Redis's ZSCAN
59
+ support, approx 10x faster. [fatkodima, #4259]
60
+ ```
61
+ zscan 0.179366 0.047727 0.227093 ( 1.161376)
62
+ enum 8.522311 0.419826 8.942137 ( 9.785079)
63
+ ```
64
+ - Respect rails' generators `test_framework` option and gracefully handle extra `worker` suffix on generator [fatkodima, #4256]
65
+ - Add ability to sort 'Enqueued' page on Web UI by position in the queue [fatkodima, #4248]
66
+ - Support `Client.push_bulk` with different delays [fatkodima, #4243]
67
+ ```ruby
68
+ Sidekiq::Client.push_bulk("class" => FooJob, "args" => [[1], [2]], "at" => [1.minute.from_now.to_f, 5.minutes.from_now.to_f])
69
+ ```
70
+ - Easier way to test enqueuing specific ActionMailer and ActiveRecord delayed jobs. Instead of manually
71
+ parsing embedded class, you can now test by fetching jobs for specific classes. [fatkodima, #4292]
72
+ ```ruby
73
+ assert_equal 1, Sidekiq::Extensions::DelayedMailer.jobs_for(FooMailer).size
74
+ ```
75
+ - Add `sidekiqmon` to gemspec executables [#4242]
76
+ - Gracefully handle `Sidekiq.logger = nil` [#4240]
77
+ - Inject Sidekiq::LogContext module if user-supplied logger does not include it [#4239]
78
+
79
+ 6.0
80
+ ---------
81
+
82
+ This release has major breaking changes. Read and test carefully in production.
83
+
84
+ - With Rails 6.0.1+, ActiveJobs can now use `sidekiq_options` directly to configure Sidekiq
85
+ features/internals like the retry subsystem. [#4213, pirj]
86
+ ```ruby
87
+ class MyJob < ActiveJob::Base
88
+ queue_as :myqueue
89
+ sidekiq_options retry: 10, backtrace: 20
90
+ def perform(...)
91
+ end
92
+ end
93
+ ```
94
+ - Logging has been redesigned to allow for pluggable log formatters:
95
+ ```ruby
96
+ Sidekiq.configure_server do |config|
97
+ config.log_formatter = Sidekiq::Logger::Formatters::JSON.new
98
+ end
99
+ ```
100
+ See the [Logging wiki page](https://github.com/mperham/sidekiq/wiki/Logging) for more details.
101
+ - **BREAKING CHANGE** Validate proper usage of the `REDIS_PROVIDER`
102
+ variable. This variable is meant to hold the name of the environment
103
+ variable which contains your Redis URL, so that you can switch Redis
104
+ providers quickly and easily with a single variable change. It is not
105
+ meant to hold the actual Redis URL itself. If you want to manually set
106
+ the Redis URL (not recommended as it implies you have no failover),
107
+ then you may set `REDIS_URL` directly. [#3969]
108
+ - **BREAKING CHANGE** Increase default shutdown timeout from 8 seconds
109
+ to 25 seconds. Both Heroku and ECS now use 30 second shutdown timeout
110
+ by default and we want Sidekiq to take advantage of this time. If you
111
+ have deployment scripts which depend on the old default timeout, use `-t 8` to
112
+ get the old behavior. [#3968]
113
+ - **BREAKING CHANGE** Remove the daemonization, logfile and pidfile
114
+ arguments to Sidekiq. Use a proper process supervisor (e.g. systemd or
115
+ foreman) to manage Sidekiq. See the Deployment wiki page for links to
116
+ more resources.
117
+ - Integrate the StandardRB code formatter to ensure consistent code
118
+ styling. [#4114, gearnode]
119
+
120
+ 5.2.7
121
+ ---------
122
+
123
+ - Fix stale `enqueued_at` when retrying [#4149]
124
+ - Move build to [Circle CI](https://circleci.com/gh/mperham/sidekiq) [#4120]
125
+
126
+ 5.2.6
127
+ ---------
128
+
129
+ - Fix edge case where a job failure during Redis outage could result in a lost job [#4141]
130
+ - Better handling of malformed job arguments in payload [#4095]
131
+ - Restore bootstap's dropdown css component [#4099, urkle]
132
+ - Display human-friendly time diff for longer queue latencies [#4111, interlinked]
133
+ - Allow `Sidekiq::Worker#set` to be chained
134
+
5
135
  5.2.5
6
136
  ---------
7
137
 
@@ -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
+ ```
@@ -4,10 +4,41 @@
4
4
 
5
5
  Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how to buy.
6
6
 
7
+ HEAD
8
+ -------------
9
+
10
+ - Periodic job registration API adjusted to avoid loading classes in
11
+ initializer [#4271]
12
+
13
+ 2.0.0
14
+ -------------
15
+
16
+ - Except for the [newly required credentials](/mperham/sidekiq/issue/4232), Sidekiq Enterprise 2.0 does
17
+ not have any significant migration steps.
18
+ - Sidekiq Enterprise must now be started with valid license credentials. [#4232]
19
+ - Call `GC.compact` if possible in sidekiqswarm before forking [#4181]
20
+ - Changes for forward-compatibility with Sidekiq 6.0.
21
+ - Add death handler to remove any lingering unique locks [#4162]
22
+ - Backoff can now be customized per rate limiter [#4219]
23
+ - Code formatting changes for StandardRB
24
+
25
+ 1.8.1
26
+ -------------
27
+
28
+ - Fix excessive lock reclaims with concurrent limiter [#4105]
29
+ - Add ES translations, see issues [#3949](https://github.com/mperham/sidekiq/issues/3949) and [#3951](https://github.com/mperham/sidekiq/issues/3951) to add your own language.
30
+
31
+ 1.8.0
32
+ -------------
33
+
34
+ - Require Sidekiq Pro 4.0 and Sidekiq 5.2.
35
+ - Refactor historical metrics API to use revamped Statsd support in Sidekiq Pro
36
+ - Add a gauge to historical metrics for `default` queue latency [#4079]
37
+
7
38
  1.7.2
8
39
  -------------
9
40
 
10
- - Add PT and JA translations, see issues [#3949](https://github.com/mperham/sidekiq/issues/3949) and [#3951](https://github.com/mperham/sidekiq/issues/3951) to add your own language.
41
+ - Add PT and JA translations
11
42
  - Fix elapsed time calculations to use monotonic clock [#4000, sj26]
12
43
  - Fix edge case where flapping leadership would cause old periodic
13
44
  jobs to be fired once [#3974]