QuestDB JavaScript Client - v5.0.0
    Preparing search index...

    Interface QwpIngressSessionOptions

    interface QwpIngressSessionOptions {
        ackTimeoutMs?: number;
        backgroundStoreAndForward?: boolean;
        catchUpCapGapMinEscalationWindowMs?: number;
        connectionListenerInboxCapacity?: number;
        durableAckKeepaliveMs?: number;
        errorInboxCapacity?: number;
        initialConnectMode?: QwpInitialConnectMode;
        maxBatchSizeBytes?: number;
        memoryReplayAppendDeadlineMs?: number;
        memoryReplayMaxBytes?: number;
        onDurableAck?: (response: QwpIngressResponse) => void;
        onError?: (event: QwpIngressErrorEvent) => void;
        onProgress?: (event: QwpIngressProgressEvent) => void;
        onResponse?: (response: QwpIngressResponse) => void;
        onSenderError?: (error: QwpSenderError) => void;
        orphanDurableAckMismatchMaxDurationMs?: number;
        orphanStoreAndForward?: boolean;
        reconnect?: false | QwpReconnectOptions;
        replayStore?: QwpIngressReplayStore;
    }
    Index

    Properties

    ackTimeoutMs?: number

    Per-frame ACK deadline. Defaults to 15 seconds. Capped at 2,147,483,647ms (the host timer ceiling); a larger value throws a RangeError.

    backgroundStoreAndForward?: boolean

    Starts memory or persistent replay without waiting for a server.

    catchUpCapGapMinEscalationWindowMs?: number

    Minimum cap-gap dwell before an orphan can be quarantined. Not capped at the host timer ceiling: compared against elapsed time only.

    connectionListenerInboxCapacity?: number

    Bounded reconnect-listener inbox. Oldest pending events are dropped when full. Defaults to 64, matching the Java client.

    durableAckKeepaliveMs?: number

    Enables durable-ACK tracking. While committed table transactions await durable upload, Node transports send WebSocket PING frames and browser transports send table-less QWP poll frames. Zero keeps tracking enabled but disables automatic polling. Factory-created browser sessions require requestDurableAck=true when this option is supplied. Capped at 2,147,483,647ms (the host timer ceiling); a larger value throws a RangeError.

    errorInboxCapacity?: number

    Bounded typed/legacy error inbox. Oldest pending errors are dropped when full. Defaults to 256, matching the Java client.

    initialConnectMode?: QwpInitialConnectMode

    Initial connection policy supplied by the Node adapter.

    maxBatchSizeBytes?: number

    Optional local ingress frame cap. Browsers cannot read WebSocket upgrade headers, so browser applications should set this to the server's configured QWP cap. When the server also advertises a cap, the smaller value wins. Table batches are split at row boundaries automatically; an individual row that cannot fit is rejected with QwpBatchTooLargeError before it is sent.

    memoryReplayAppendDeadlineMs?: number

    Maximum time a memory replay append waits for ACK-driven trimming after reaching memoryReplayMaxBytes. Defaults to 30 seconds.

    memoryReplayMaxBytes?: number

    Target cap for the built-in memory-only replay queue, including estimated per-frame bookkeeping. Defaults to 128 MiB. A transaction-closing logical batch may temporarily exceed this target by up to one target-sized batch, because the server cannot ACK its deferred prefix before receiving that batch. This applies in browsers and non-persistent Node sessions; custom replay stores enforce their own cap.

    onDurableAck?: (response: QwpIngressResponse) => void
    onError?: (event: QwpIngressErrorEvent) => void

    Server rejections, deadlines, and terminal session failures.

    onProgress?: (event: QwpIngressProgressEvent) => void

    Monotonic send/accept/durability notifications. Callback errors are ignored.

    onResponse?: (response: QwpIngressResponse) => void
    onSenderError?: (error: QwpSenderError) => void

    Java-parity typed server-rejection and data-loss notifications. When omitted, the default handler logs retriable errors at warn and terminal errors or abandoned data at error.

    orphanDurableAckMismatchMaxDurationMs?: number

    Consecutive durable-ACK gap budget retained for orphan SF. Not capped at the host timer ceiling: compared against elapsed time only.

    orphanStoreAndForward?: boolean

    Orphan sessions may quarantine persistent catch-up cap gaps.

    reconnect?: false | QwpReconnectOptions

    Bounded reconnection and at-least-once replay policy. Reconnection is enabled by default for factory-created sessions; set false to keep one fixed connection. Browser and non-persistent Node replay is memory-only.

    An ACK lost during disconnect can cause a frame to be replayed after the server accepted it; configure server-side deduplication when duplicates are not acceptable.

    replayStore?: QwpIngressReplayStore

    Node adapter hook for persistent store-and-forward.