Anchorage API reference
    Preparing search index...

    Class SignalProviderHost<TEnv>Abstract

    The provider host DO base. Subclass it, supply build() (the tenant-bound subscription store + thread topology + provider list from env), and bind the subclass under a wrangler namespace addressed idFromName(tenantId).

    Routes: POST /arm boots and arms the alarm; POST /poll runs one poll cycle directly for deterministic health checks that do not depend on the alarm timer. alarm() polls and then re-arms.

    Type Parameters

    • TEnv = unknown
    Index

    Constructors

    Properties

    Accessors

    Methods

    Constructors

    Properties

    env: TEnv

    Accessors

    • get tenantId(): string

      The tenant this host serves, recovered from its OWN idFromName identity — id.name is the bare tenantId. It is pattern-validated and fail-closed: a name carrying no valid tenant cannot scope a store.

      Returns string

    Methods

    • Run one poll cycle across this tenant's poll-capable providers, rehydrating each provider's subscriptions from D1 first (the eviction-survivable path). PER-PROVIDER isolation: a provider whose poll throws is logged and skipped, the rest still run; PER-DELIVERY isolation: a failing/tampered delivery is logged and skipped, the batch continues. Public so a host or test can drive it directly.

      Returns Promise<PollResult>