Skip to content

Home / node / GlideClusterClient / namespaces / GlideClusterClientConfiguration / interfaces / PubSubSubscriptions @valkey/valkey-glide


@valkey/valkey-glide / GlideClusterClient / GlideClusterClientConfiguration / PubSubSubscriptions

Interface: PubSubSubscriptions

Configuration for Pub/Sub subscriptions that the client will establish upon connection.

Properties

callback()?

optional callback: (msg, context) => void

Optional callback to accept the incoming messages.

Parameters

msg

PubSubMsg

context

any

Returns

void


channelsAndPatterns

channelsAndPatterns: Partial\<Record\<PubSubChannelModes, Set\<string>>>

Channels and patterns by modes.


context?

optional context: any

Arbitrary context to pass to the callback.