export declare class PubSubRedisBroker<TEvents extends Record<string, any>> extends BaseRedisBroker<TEvents> implements IPubSubBroker<TEvents>
PubSub broker powered by Redis
Type Parameters
Record<string, any> TEvents extends
protectedboolean listening :
Whether this broker is currently polling events
Inherited from: BaseRedisBroker
protectedreadonlyRequired<RedisBrokerOptions> options :
Options this broker is using
Inherited from: BaseRedisBroker
Used for Redis queues, see the 3rd argument taken by xadd
Inherited from: BaseRedisBroker
protectedreadonlyRedis streamReadClient :
Internal copy of the Redis client being used to read incoming payloads
Inherited from: BaseRedisBroker
protectedreadonlySet<string> subscribedEvents :
Events this broker has subscribed to
Inherited from: BaseRedisBroker
destroyPromise<void> () :
Destroys the broker, closing all connections
Inherited from: BaseRedisBroker
Begins polling for events, firing them to listen
Inherited from: BaseRedisBroker
publishT extends keyof TEvents
>(event: Tdata: TEvents[T]) : Promise<void> <
T extends keyof TEvents
Publishes an event
Subscribes to the given events, grouping them by the given group name
Inherited from: BaseRedisBroker
Unsubscribes from the given events - it's required to pass the same group name as when subscribing for proper cleanup
Inherited from: BaseRedisBroker