OptionalauthAuthenticates every WebSocket upgrade with a credential carried in its
subprotocol offer instead of a session cookie. This is how a web
application served from another origin, which QuestDB lists in
qwp.browser.allowed.origins, connects. Pass a fixed credential, or a
QwpBrowserAuthProvider the client calls before every connect,
reconnect, and failover attempt, for example to supply a refreshed OIDC
access token. Under a client's cluster it authenticates both sides, and
a provider is called before every connection attempt of either side.
QuestDB accepts the credential only from a listed origin: a page served
from QuestDB's own origin must be listed too, or keep using
sessionBootstrap. It creates no session for the credential and ignores
cookies on the upgrade. Use wss:: the credential travels in the opening
HTTP request. Cannot be combined with sessionBootstrap.
OptionalbufferMaximum decoded batches waiting for a consumer. Defaults to 4.
OptionalcancelMaximum wait for a terminal response after CANCEL, and the grace period of
a query timeout: how long an expired query may take to end before its
caller is released, and how long its connection may then take to drain
it. Defaults to 5 seconds. Capped at 2,147,483,647ms (the host timer
ceiling); a larger value throws a RangeError.
OptionalcloseMaximum time allowed for a graceful WebSocket close. Defaults to 15s.
Capped at 2,147,483,647ms (the host timer ceiling); a larger value throws
a RangeError.
OptionalcompressionRequests Zstd-compressed result batches through browser-visible URL negotiation. Defaults to raw for compatibility.
OptionalcompressionZstd level hint. Must be between 1 and 22, and only takes effect
alongside compression; the default raw negotiates no compression for
a level to travel on.
OptionalconnectionBounded inbox depth for reconnect.onEvent. Defaults to 64, matching
ingress. Overflow drops the oldest pending notification.
OptionalconnectNode TCP/TLS connection deadline, or the complete opening deadline in a
browser. Defaults to 15s. Capped at 2,147,483,647ms (the host timer
ceiling); a larger value throws a RangeError.
OptionalfailoverAdditional endpoints attempted in order when the preferred endpoint fails.
OptionalinitialDefault per-query send-ahead credit. Defaults to zero (unbounded).
OptionalmaxRequests a server-side RESULT_BATCH row cap, and rejects a batch that declares more rows: decoder scratch is sized from the declared row count and retained for the session's lifetime.
OptionalonDefault notification immediately before an active query is re-executed. Not-yet-consumed batches are discarded automatically; callers that retain an already-consumed prefix should discard it here. A query's own onFailoverReset overrides this callback, which is important for pooled sessions whose request IDs may overlap.
OptionalprotocolsOptionalqueryDefault per-query timeout, measured from the query() call. Zero or
undefined disables query timeouts. Once it expires no further batch is
delivered and the query is cancelled; see
QwpEgressQueryOptions.timeoutMs for how the outcome is reported.
The connect-string key is query_timeout_ms. Capped at 2,147,483,647ms
(the host timer ceiling); a larger value throws a RangeError.
OptionalreconnectBounded failover policy. Failover and at-least-once active-query replay are enabled by default; set false to keep one fixed connection.
OptionalsendMaximum time a send may remain queued by the WebSocket. Defaults to 15s.
Capped at 2,147,483,647ms (the host timer ceiling); a larger value throws
a RangeError.
OptionalserverSERVER_INFO handshake deadline. Defaults to 5 seconds. Capped at
2,147,483,647ms (the host timer ceiling); a larger value throws a
RangeError.
OptionalsessionAuthenticates over REST before every WebSocket connection attempt so the
browser can attach QuestDB's HttpOnly session cookies to the upgrade.
Without a url, it targets /exec beside the endpoint being connected.
Cannot be combined with auth.
OptionaltargetSelects any readable node, a primary/standalone node, or a replica.
OptionalwebTest or framework hook; defaults to the browser's global WebSocket. Under
a client's cluster it is shared, and either side may override it.
OptionalzoneOpaque, case-insensitive preferred zone; cross-zone fallback stays enabled.
Everything a browser QWP query session takes: the connection, endpoint routing, result compression, and the session's flow control, deadlines and failover.