Expand description
连接池 + 发布/订阅(v2) 不影响现有 redis.rs 的逻辑
Statics§
- REDIS_
POOL - 全局 Redis 连接池
Functions§
- init_
redis_ pool - 初始化 Redis 连接池 let redis_url = “redis://127.0.0.1/”;
- publish_
notify - 用连接池发布消息
- subscribe_
notify - 使用独立连接订阅消息 - 不走连接池(没必要,在调用订阅处用一个长连接保持就行)