From b5ac4a175941f0fdfd1979e32f699b63f99a2700 Mon Sep 17 00:00:00 2001 From: Madhavendra Rathore Date: Mon, 8 Jun 2026 15:59:25 +0000 Subject: [PATCH] chore(sea): bump KERNEL_REV to kernel main (#144 merged) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Point the SEA napi binding at databricks-sql-kernel main HEAD 9c2e2378 ("SEA parity batch: metadata PK/FK reshape + retry/backoff kwargs + DNS fast-fail", kernel #144), up from the stale 80b68e1e. Regenerated native/sea/index.d.ts from the bumped kernel surface (the only committed binding artifact that changed; the .node binary is gitignored and rebuilt by CI). New surface from #144: - ConnectionOptions: retryMinWaitSecs / retryMaxWaitSecs / retryMaxAttempts / retryOverallTimeoutSecs (retry/backoff knobs, mirroring the pyo3 retry_* kwargs). - AsyncStatement: numModifiedRows() / displayMessage() / diagnosticInfo() / errorDetailsJson() (rich status accessors). All additions are additive/optional — no removals. Verified: `npm run build:native` against a kernel checkout at 9c2e2378 builds cleanly, and `tsc` type-checks lib/ against the regenerated binding. This bump only repoints + regenerates the binding; wiring the new options into the driver's TypeScript layer is separate follow-up. Co-authored-by: Isaac Signed-off-by: Madhavendra Rathore --- KERNEL_REV | 2 +- native/sea/index.d.ts | 39 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+), 1 deletion(-) diff --git a/KERNEL_REV b/KERNEL_REV index 65457d79..5315ee8b 100644 --- a/KERNEL_REV +++ b/KERNEL_REV @@ -1 +1 @@ -80b68e1eef3b613910183a50dfa4dace854d50dd +9c2e2378f9a0bcee7d2750371392c07cac38fc3d diff --git a/native/sea/index.d.ts b/native/sea/index.d.ts index f8105ff6..2829489c 100644 --- a/native/sea/index.d.ts +++ b/native/sea/index.d.ts @@ -332,6 +332,34 @@ export interface ConnectionOptions { * `User-Agent` entry here. */ customHeaders?: Array + /** + * Retry/backoff tuning — all optional. An unset field keeps the kernel's + * built-in policy (1s/60s exponential backoff, 6 total attempts, 900s + * budget). Mirrors the pyo3 binding's `retry_*` kwargs so the Node.js + * driver can forward the same retry knobs the Python connector does. + * + * Lower bound of the exponential backoff (also clamps a server + * `Retry-After`). Maps onto [`HttpConfig::retry_min_wait`]. + */ + retryMinWaitSecs?: number + /** + * Upper bound of the exponential backoff. Maps onto + * [`HttpConfig::retry_max_wait`]. + */ + retryMaxWaitSecs?: number + /** + * **Total** number of attempts (matching the connector's + * `_retry_stop_after_attempts_count` and JDBC count semantics). The + * kernel's [`HttpConfig::retry_max_retries`] counts retries *after* the + * first attempt, so this is converted with `max(0, attempts - 1)` in + * [`build_http_config`] — `0` / `1` both mean a single attempt, no retry. + */ + retryMaxAttempts?: number + /** + * Overall retry budget in whole seconds. Maps onto + * [`HttpConfig::overall_timeout`]. + */ + retryOverallTimeoutSecs?: number } /** * Open a Databricks SQL session and return an opaque `Connection` @@ -505,6 +533,17 @@ export declare class AsyncStatement { * that only need the state name. */ status(): Promise + /** Rows modified by the statement (UPDATE / INSERT / DELETE / MERGE). */ + numModifiedRows(): Promise + /** + * Server-supplied user-facing message (may contain SQL fragments — + * redact before centralised logging). + */ + displayMessage(): Promise + /** Server-supplied diagnostic detail. */ + diagnosticInfo(): Promise + /** Server-supplied structured error detail (JSON), when enabled. */ + errorDetailsJson(): Promise /** * Block until the server reaches a terminal state, then return * an `AsyncResultHandle` that wraps the materialised result