-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Redis v6 clear() bug when using lazy:true #51679
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Can you please submit a bug report to phpredis? Looks like this should be fixed there. |
I think this PR fixes the problem: phpredis/phpredis#2363 (comment) They merged it to develop branch but I don't know when they will release a new version. You can close this issue if you want. |
Ouh, you are the author of the fix xD Do you know when pecl will release a new version with your changes? |
Hello awesome symfony people. I also seem to be having a problem with the cache and phpredis v6. I am using the However I can still invalidate specific tags with |
As this bug is fixed upstream, lets close here. @yakobe please open a new issue, so that we don't lost track on this, thanks |
…y behaviors of internal classes (nicolas-grekas) This PR was merged into the 6.3 branch. Discussion ---------- [Cache][VarExporter] Fix proxy generation to deal with edgy behaviors of internal classes | Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix #51770, #51679, #51700 | License | MIT Instead of #51838 This fixes the issue by not passing default values explicitly when they were not provided during the call to the method. Commits ------- c66a2f7 [Cache][VarExporter] Fix proxy generation to deal with edgy behaviors of internal classes
Symfony version(s) affected
6.3.0
Description
Redis doesn't clear the namespace when using lazy=true (on redis connection or symfony container service)
How to reproduce
Possible Solution
I don't know if this is a bug in redis but symfony can fix it chaning the
RedisProxy::scan
function:Note: this works only for lazy=true on redis conection but the error still exists for lazy=true on symfony container service
Additional Context
The
RedisTrait::doClear
function scan all the keys in the namespace:symfony/src/Symfony/Component/Cache/Traits/RedisTrait.php
Line 471 in 4ba165a
When using
lazy: true
parameter (in symfony container service or redis connection), the RedisProxy propagates all the function arguments to theredis::scan
function:symfony/src/Symfony/Component/Cache/Traits/Redis6Proxy.php
Line 891 in 4ba165a
The problem is: redis doesn't return keys if we send $type=null as parameter
Seems to be related with: phpredis/phpredis#2362
The text was updated successfully, but these errors were encountered: