Type Alias StreamClientConfiguration

StreamClientConfiguration: {
    cursor?: string;
    httpStreamClient: HTTPStreamClient;
    logger: LogHandler;
    long_type: "number" | "bigint";
    max_attempts: number;
    max_backoff: number;
    secret: string;
    status_events?: boolean;
}

Configuration for a streaming client. This typically comes from the Client instance configuration.

Type declaration

  • Optionalcursor?: string

    The last seen event cursor to resume the stream from. When provided, the stream will start from the given cursor position (exclusively).

  • httpStreamClient: HTTPStreamClient

    The underlying HTTPStreamClient that will execute the actual HTTP calls

  • logger: LogHandler

    A log handler instance.

  • long_type: "number" | "bigint"

    Controls what Javascript type to deserialize Fauna longs to.

  • max_attempts: number

    Max attempts for retryable exceptions.

  • max_backoff: number

    Max backoff between retries.

  • secret: string

    A secret for your Fauna DB, used to authorize your queries.

  • Optionalstatus_events?: boolean

    Indicates if stream should include "status" events, periodic events that update the client with the latest valid timestamp (in the event of a dropped connection) as well as metrics about the cost of maintaining the stream other than the cost of the received events.