-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
RedisCluster scan_iter does not return all keys from all nodes #2003
Comments
Update: I did not realize that I have since found a related issue:
I believe the source of this issue is that |
Just as a followup, a rollback to redis-py-cluster resolved the issues that we were facing in our integration tests which is more evidence that there may be some implementation bug in the scanning mechanism on clusters of nodes. This is using redis 3.5.3 and redis-py-cluster 2.1.3. |
I think you're right, the documentation could definitely be better. Generally cluster support is just started! While we worked with @Grokzen and @barshaul on moving this in, it's definitely not done! Any chance @felixwang9817 you'd like to contribute a docs PR that you think might better help everyone out? |
Version: What redis-py and what redis version is the issue happening on?
redis-py==4.1.2
andredis-cli 6.2.6
Platform: What platform / version? (For example Python 3.5.1 on Windows 7 / Ubuntu 15.10 / Azure)
Python 3.7.12 on MacOS 11.4
Description: I started a local Redis cluster with 6 nodes (3 master nodes with ports 6001-6003, 3 slave nodes with ports 6004-6006). I wrote 19 total items to the Redis cluster: 1 is stored by 6001, 13 by 6002, and 5 by 6003. I confirmed this by doing
for each of the 3 master nodes.
However, when I call
client.scan_iter(b"*")
, I get a list containing only a single key, which is the key from node 6001. Here myclient
object was constructed as follows:This looks to me like there is an issue with
scan_iter
on RedisClusters, where it doesn't return all keys from all nodes.The text was updated successfully, but these errors were encountered: