Closed (fixed)
Project:
Redis
Version:
7.x-3.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
12 Aug 2019 at 07:38 UTC
Updated:
14 Jun 2022 at 21:39 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
alesr commentedThe delete() method was deprecated.
Method del() should be used instead after looking into Redis 5 documentation.
There are just two references in Redis client object in Drupal 7.x-3.x-dev version where delete() is used instead of del() which is changed in the patch that is attached.
Comment #3
littlepixiez commented#2 works for me on version 7.x-3.17; we just upgraded to php-redis 5.0.2 and these errors started filling our logs. Thanks a lot @alesr!
Comment #4
klausiLooks good, thanks!
Comment #5
shaneonabike commentedAlso works great for me could we push this to the latest dev?
Comment #6
julienjoye commentedHey, I re-rolled #2 patch for those who still run drupal/redis:2.15 (yeah I know..)
Cheers.
Comment #7
julienjoye commentedComment #8
WiseMike commented#2 works for me. Thanks a lot @alesr!
Comment #9
damienmckennaWhen was this method added? Would committing this change break any sites running older versions of phpredis? Does there need to be some sort of switch to indicate which method to use?
Comment #10
alesr commentedFrom php-redis documentation: https://github.com/phpredis/phpredis#del-delete-unlink
Note: delete is an alias for del and will be removed in future versions of phpredis.Which they did in php-redis 5 so both del() and delete() work in older version, but only del() works from 5+.
Comment #11
Rafal LukawieckiI have applied this patch in our production environment and I am happy to report that it works and solved the issue of the errors. In our case those errors were more than just log spam, they were causing the site's PHP FPM to time out—I suppose there was a caching related issue caused by the Redis update.
Many thanks for the patch, it has my vote to be merged into the development branch.
Comment #12
xito commentedI tested the patch on my site and it fix the issue with REDIS.
So, I give my vote to be merged on the dev branch.
Thanks @alers
Comment #13
heddnThe del command was only aliased/added in 3.x of php-redis. Does this need to support v2, where it wasn't aliased?
Comment #14
heddnI don't see any widely documented version constraints of what version folks need to use php-redis. Can we add a BC layer in there and see if
delexists? Otherwise we might break sites w/ older versions of the upstream library.Comment #15
damienmckennaAgreed, it should either check to see which API is being used or provide an option to control that on the settings page (like the Memcache module does), and then do a quick if/else check to determine which API to use.
Comment #16
heddnSince this is D7, let's not get too fancy. Let's try this on for size. No interdiff as this is a different approach.
Comment #17
rob230 commentedPatch #16 working well for us.
Comment #18
rob230 commentedComment #19
damienmckennaThe same as #16 only with a comment on the new method.
Comment #20
mattdaniel commentedPatch #19 is working for us, thank you!
Comment #21
jedihe commentedPatch #19 worked for me; using php redis extension 5.1.1 with a D7 site.
Just a note for anybody wanting more details: using redis 4.3.0 (sudo pecl install redis-4.3.0) also works, since the deprecation notice was added starting with version 5. Of course, the best course of action is to utilize the newer version, if possible.
Comment #22
glynster commented#19 resolved the problem for us as well. We are now able to use the latest version og php-redis 5.1.1. Thank you @DamienMcKenna RTBC +1
Comment #23
qzmenkoAfter upgrading php-redis to version 5, I'm also starting to see a new error:
Seems like we need to change
$client->multi(Redis::PIPELINE)to$client->multi()as this was done in patch for D8 version of module in related issue https://www.drupal.org/project/redis/issues/3068810#comment-13218617Attached patch with interdiff.
Comment #24
qzmenkoComment #25
eiriksmGreat! Works for me!
Comment #26
schnippy commentedPatch at #23 successfully resolved the issue for me.
Comment #27
sokru commented#19 worked for me.
#23 @qzmenko I haven't had similar errors, but I'm running redis-server 3.0.6.
Comment #28
i-trokhanenko#19 works for me too, tested with Drupal 7.69, php7.3, redis 3.0.6
Thanks
Comment #29
markdorisonPatch #23 is working as expected for me.
Comment #30
summit commentedHi, #23 is great. Thanks! Can this please be committed?
Thanks a lot in advance!
greetings and stay save, Martijn
Comment #31
hey_germano+1 for the patch in #23.
Comment #32
delacosta456 commentedhi
#23 is ok for me too on config below
- Panoply distro 1.72(D7.69)
-php7.1.31
-redis5.2.1
Thanks
Comment #33
dandaman commented+1 to patch #23.
Tested on a few sites which were upgraded from Redis 3.x to 5.x and it worked great!
Comment #34
AmiOta commentedCan you add this to a new release, please?
Comment #35
torgospizzaPatch in #23 also worked for me in clearing up those warnings, and made my Drupal 7 install much faster in return.
Comment #36
spjsche commentedThanks for the effort on the patch, but is there any chance for it to be committed.
Stay SAFE.
Comment #37
damienmckennaComment #38
jefflogan commented+1 for patch in #23
Comment #39
dbouman commented+1 patch #23 worked for me too
Comment #40
dydave commentedHi everyone,
Thank you very much for contributing a patch to this issue.
I would like to confirm patch from #23 applied without error and fixed the problem in my case, with:
Confirming patch could be committed and added to the module.
Thanks!
Comment #41
johan den hollander commentedHi everyone,
Thank you very much for contributing a patch to this issue.
I would like to confirm patch from #23 applied without error and fixed the problem in my case, with:
Drupal 7.82
Redis 7.x-3.18
Phpredis version 6.2
Confirming patch could be committed and added to the module.
Thanks!
Comment #42
SoportePRO commentedI see in the Redis website (https://redis.io/download) that the latest stable version until today is 6.2.5 (09/2021). This module and patch works with it?
Comment #43
damienmckennaThis is required when using PHP 7.4 on Pantheon.
Comment #44
caesius commentedConfirming that #23 works after running into this on Pantheon.
Comment #45
jtjones23 commentedConfirming that #23 works when running on Pantheon.
Drupal 7.82
PHP 7.4
MariaDB 10.4
Comment #46
nicobot commentedConfirm #23 fixes the problem on Pantheon.
Thank you!
Comment #47
maskedjellybeanAnother confirmation #23 fixes the problem on Pantheon.
Thank you!
Comment #49
kporras07 commentedWorks great! Committed. Thanks!