Skip to content

提高redis依赖兼容性:兼容 redis4+#308

Open
yunjiangao-beep wants to merge 1 commit intoBoris-code:masterfrom
yunjiangao-beep:fix-bug
Open

提高redis依赖兼容性:兼容 redis4+#308
yunjiangao-beep wants to merge 1 commit intoBoris-code:masterfrom
yunjiangao-beep:fix-bug

Conversation

@yunjiangao-beep
Copy link

  1. 将 Redis 客户端调用从 StrictRedis 迁移为 Redis,统一 from_url 与普通连接写法,适配 redis4+;
  2. 调整集群模式实现,改为使用 redis.cluster.RedisCluster 与 ClusterNode;
  3. 为集群导入增加显式异常提示,避免低版本环境下报错信息不明确;
  4. 优化 sdelete 的 sscan 游标循环终止逻辑,避免类型差异带来的潜在死循环;
  5. 将 execute_command 改为参数化调用(如 KEYS/TYPE/MEMORY USAGE),提升新版本兼容性;
  6. 依赖声明更新为 redis>=4.1.0,并移除 redis-py-cluster。

2. 调整集群模式实现,改为使用 redis.cluster.RedisCluster 与 ClusterNode;
3. 为集群导入增加显式异常提示,避免低版本环境下报错信息不明确;
4. 优化 sdelete 的 sscan 游标循环终止逻辑,避免类型差异带来的潜在死循环;
5. 将 execute_command 改为参数化调用(如 KEYS/TYPE/MEMORY USAGE),提升新版本兼容性;
6. 依赖声明更新为 redis>=4.1.0,并移除 redis-py-cluster。
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant