SPUBLISH
Since 1.1.0Pub/Sub
Syntax
SPUBLISH shardchannel messageSends message to the clients subscribed to the shard channel shardchannel with SSUBSCRIBE. Shard channels are separate from ordinary ones: PUBLISH does not reach shard subscribers, and patterns do not match shard channels.
Reply
- The number of clients that got the message.
Examples
client 1> SSUBSCRIBE orders
1) "ssubscribe"
2) "orders"
3) (integer) 1
client 2> SPUBLISH orders o1
(integer) 1
client 2> PUBLISH orders x
(integer) 0
client 1>
1) "smessage"
2) "orders"
3) "o1"