Pipelining commands on a Redis instance is deprecated and will be removed in Redis 5.0.0
Asked Answered
V

3

7

I am using redis version 6.0 and gem 'sidekiq', '>= 6.4.1' gem 'sidekiq-cron', '~> 1.2' for job scheduling in rails. I am using corn job to process email daily. [pipeline commands on a redis is deprecated. My ruby version is 2.7, rails version is 6.1 and using ubuntu 20.07.

Vagina answered 21/2, 2022 at 16:10 Comment(2)
Run gem list --local | grep redis and you will see the version of the redis Ruby gem, not the version of Redis server itself. I agree this warning is a little bit confusing.Nuzzle
Ya it's 4.6.0 @chemturionVagina
A
5

The issue was fixed by the Sidekiq team in their latest version v6.4.1 . If still there are warnings then it is due to the sidekiq-cron gem. It has been discussed and and fixed in a forked branch here - ondrejbartas/sidekiq-cron#310 (comment) We would need to do the following while adding sidekiq cron in the gemfile:

"sidekiq-cron", git: "https://github.com/citusdata/sidekiq-cron", branch: "hotfix/pipelining_depreciation"

This worked for me. Hope it would help you.

Update Aug 8 2023: The repository "https://github.com/citusdata/sidekiq-cron" does not exist anymore and the fix is included in the latest version of Sidekiq Cron gem 1.10.1 to fix the warning. We can update the Gemfile code to install gem 'sidekiq-cron', '~> 1.10.1' to fix the issue.

gem 'sidekiq-cron', '~> 1.10.1' 
Antibiosis answered 25/2, 2022 at 11:15 Comment(0)
H
0

I was still getting this error after updating sidekiq to v6.4.1. The error seemed to be coming from a dependent gem of resque, redis-namespace. So I updated the resque gem and that fixed the issue for me.

Homothallic answered 9/9, 2022 at 15:6 Comment(0)
A
0

I upgraded my sidekiq and still having this error. Then, I realize one obvious thing to check is if you use the old pipeline like this:

r.multi do
  r.hset(key, next_cache)
end

should be

r.multi do |pipeline|
  pipeline.hset(key, next_cache)
end
Allhallowtide answered 4/9, 2023 at 6:49 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.