redis笔记——消息发布与消息订阅

1.publish channel message:发布频道 publish news "hello" 发布消息到news 频道

2.subscribe channel [channel2] : 订阅频道(可以同时订阅多个频道)

3.unsubscribe channel [channel2] : 退订指定的频道 (可以退订多个频道)

4.psubscribe channel* :订阅一个或多个符合给定模式的频道 p(pattern)

5.pubsubscribe channel* :退订所有给定模式的频道

6.PUBSUB CHANNELS:返回由活跃频道组成的列表

 

posted @ 2018-03-28 15:53  我是胖子搬运工  阅读(127)  评论(0编辑  收藏  举报