I'm testing redis-py
: https://github.com/andymccurdy/redis-py.
I have a hard time figuring out how to call and get output for the redis
command PUBSUB channels
.
I'm testing redis-py
: https://github.com/andymccurdy/redis-py.
I have a hard time figuring out how to call and get output for the redis
command PUBSUB channels
.
To get all channels:
chans = r.pubsub_channels()
To get the number of subscribers to a channel:
num = r.pubsub_numsub('channel')