PSubscribe subscribes the client to the given patterns. Patterns can be omitted to create empty subscription.
(ctx context.Context, channels ...string)
| 2261 | // PSubscribe subscribes the client to the given patterns. |
| 2262 | // Patterns can be omitted to create empty subscription. |
| 2263 | func (c *ClusterClient) PSubscribe(ctx context.Context, channels ...string) *PubSub { |
| 2264 | pubsub := c.pubSub() |
| 2265 | if len(channels) > 0 { |
| 2266 | _ = pubsub.PSubscribe(ctx, channels...) |
| 2267 | } |
| 2268 | return pubsub |
| 2269 | } |
| 2270 | |
| 2271 | // SSubscribe Subscribes the client to the specified shard channels. |
| 2272 | func (c *ClusterClient) SSubscribe(ctx context.Context, channels ...string) *PubSub { |
nothing calls this directly
no test coverage detected