Setu-TS
    Preparing search index...

    Class RedisStreamsBroker

    Redis Streams message broker implementation.

    Uses Redis Streams for persistent message delivery with consumer groups for load-balanced processing.

    0.1.0

    Implements

    • MessageBrokerAdapter
    Index
    • Publishes a message to a topic (Redis stream).

      Type Parameters

      • T

        The message payload type

      Parameters

      • topic: string

        The topic (stream name) to publish to

      • message: T

        The message payload

      • Optionaloptions: PublishOptions

        Caller headers, ordering key and de-duplication id

      Returns Promise<void>

      Resolves when published

      When publishTimeoutMs expires; delivery remains possible

      0.1.0

    • Internal

      Publishes with framework-owned headers under the configured acknowledgement bound.

      Type Parameters

      • T

      Parameters

      • topic: string

        Destination topic

      • message: T

        Payload to serialize

      • headers: Readonly<Record<string, string>>

        Framework-owned transport headers

      • Optionaloptions: PublishOptions

        Caller headers, ordering key and de-duplication id

      Returns Promise<void>

      Resolves when the transport acknowledges the publish

      When publishTimeoutMs expires; delivery remains possible

    • Tri-state backend reachability (M70c).

      ioredis auto-reconnects via its default retry strategy, so the broker does not run a reconnect loop of its own; the truth is what ping() reports right now. true when ping() resolves, false when it rejects (the server is down or the socket is mid-reconnect), undefined when the injected client exposes no ping (a minimal fake) — in which case the indicator reports reachable: 'unknown' rather than lying.

      Returns Promise<boolean | undefined>

      true/false/undefined as described

      0.1.0