2016-12-31 17:42:52 -05:00
|
|
|
# Welcome to Sidekiq 5.0!
|
|
|
|
|
|
|
|
Sidekiq 5.0 contains a reworked job dispatch and execution core to integrate
|
2017-01-18 15:52:26 -05:00
|
|
|
better with the new Rails 5.0 Executor. It also drops support for older
|
2017-03-20 12:41:20 -04:00
|
|
|
versions of Ruby and Rails and adds support for RTL languages in the Web UI.
|
2016-12-31 17:42:52 -05:00
|
|
|
|
|
|
|
## What's New
|
|
|
|
|
2017-03-20 12:41:20 -04:00
|
|
|
* Integrate job logging and retry logic directly in with the job
|
2016-12-31 17:42:52 -05:00
|
|
|
execution logic in Sidekiq::Processor. Previously this logic was
|
2017-01-17 16:02:06 -05:00
|
|
|
defined as middleware. In Rails 5.0, ActiveSupport::Executor handles ActiveRecord
|
2016-12-31 17:42:52 -05:00
|
|
|
connection management, job callbacks, development mode class loading,
|
|
|
|
etc. Because of its extensive responsibilities, the Executor can't be
|
|
|
|
integrated as Sidekiq middleware; the logging/retry logic had to be pulled out
|
|
|
|
too. Sidekiq 4.2 had a hack to make it work but this redesign provides
|
2017-01-02 15:29:58 -05:00
|
|
|
a cleaner integration. [#3235]
|
2016-12-31 17:42:52 -05:00
|
|
|
* The Delayed Extensions `delay`, `delay_in` and `delay_until` APIs are
|
|
|
|
no longer available by default. The extensions allow you to marshal
|
|
|
|
job arguments as YAML, leading to cases where job payloads could be many
|
|
|
|
100s of KB or larger if not careful, leading to Redis networking
|
|
|
|
timeouts or other problems. As noted in the Best Practices wiki page,
|
|
|
|
Sidekiq is designed for jobs with small, simple arguments.
|
|
|
|
|
|
|
|
Add this line to your initializer to re-enable them and get the old behavior:
|
2017-01-09 12:58:18 -05:00
|
|
|
```ruby
|
|
|
|
Sidekiq::Extensions.enable_delay!
|
|
|
|
```
|
2017-01-02 15:29:58 -05:00
|
|
|
The old `Sidekiq.remove_delay!` API has been removed as it is now the default. [#3299]
|
|
|
|
* Sidekiq's quiet signal is now `TSTP` (think of it as **T**hread
|
|
|
|
**ST**o**P**) instead of USR1 as USR1 is not available on JRuby.
|
|
|
|
USR1 will continue to be supported in Sidekiq 5.x for backwards
|
|
|
|
compatibility and will be removed in Sidekiq 6.x. [#3302]
|
2017-03-16 16:51:29 -04:00
|
|
|
* The Web UI is now bi-directional - it can render either LTR
|
2017-03-20 12:41:20 -04:00
|
|
|
(left-to-right) or RTL languages. With this change, **Farsi, Arabic,
|
|
|
|
Hebrew and Urdu** are officially supported. [#3381]
|
2017-01-17 16:02:06 -05:00
|
|
|
* Rails 3.2 is no longer supported.
|
|
|
|
* Ruby 2.0 and Ruby 2.1 are no longer supported. Ruby 2.2.2+ is required.
|
2017-01-17 17:58:08 -05:00
|
|
|
* Jobs which can't be parsed due to invalid JSON are now pushed
|
2017-01-18 15:52:26 -05:00
|
|
|
immediately to the Dead set since they require manual intervention and
|
|
|
|
will never execute successfully as is. [#3296]
|
2017-01-17 17:58:08 -05:00
|
|
|
|
2016-12-31 17:42:52 -05:00
|
|
|
## Upgrade
|
|
|
|
|
|
|
|
As always, please upgrade Sidekiq **one major version at a time**.
|
|
|
|
If you are already running Sidekiq 4.x, then:
|
|
|
|
|
|
|
|
* Upgrade to the latest Sidekiq 4.x.
|
|
|
|
```ruby
|
|
|
|
gem 'sidekiq', '< 5'
|
|
|
|
```
|
|
|
|
* Fix any deprecation warnings you see.
|
|
|
|
* Upgrade to 5.x.
|
|
|
|
```ruby
|
|
|
|
gem 'sidekiq', '< 6'
|
|
|
|
```
|