redis - How to determine number of clients listening for broadcasting? -


i using laravel 5.1 , want know how many clients listening particular channel test-channel. want number on server? there way can it? further using broadcasting redis.

the link broadcasting document follows:

laravel 5.1 event broadcasting

there command in redis. check out pubsub numsub:

returns number of subscribers (not counting clients subscribed patterns) specified channels.

and pubsub numpat:

returns number of subscriptions patterns (that performed using psubscribe command). note not count of clients subscribed patterns total number of patterns clients subscribed to.

edit: it's worth noting publish command returns number of receivers:

return value

integer reply: number of clients received message.


Comments

Popular posts from this blog

facebook - android ACTION_SEND to share with specific application only -

python - Creating a new virtualenv gives a permissions error -

javascript - cocos2d-js draw circle not instantly -