You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* [SEA-NodeJS] Kernel-parity batch: mTLS + custom headers/UA + retry/backoff + operation-status fields
Squashed rebase of the SEA kernel-parity batch onto current main
(replaces the prior multi-commit branch, which had diverged with
unsigned commits and a merge-commit history that conflicted with the
since-merged databricks#424/databricks#426). Net feature set unchanged:
- mTLS (clientCertPem/clientKeyPem) + custom HTTP headers + User-Agent
entry on the SEA path, with PEM and header-token (CR/LF/NUL)
validation in SeaAuth.
- Retry/backoff tuning forwarded to the kernel (omitting unset knobs).
- Operation-status fields surfaced through op.status(): numModifiedRows,
displayMessage, diagnosticInfo, errorDetailsJson (async + sync paths),
memoized once terminal; Thrift wire synthesis maps the same fields.
- preserveBigNumericPrecision connection option (Thrift + SEA) and
DATE/large-number parameter type-inference fix.
Co-authored-by: Isaac
Signed-off-by: Madhavendra Rathore <madhavendra.rathore@databricks.com>
* fix(sea): address review findings + bump KERNEL_REV to kernel main; prettier
Review findings (GopalDB / code-review agent), each validated:
1. DBSQLParameter DATE off-by-one in non-UTC timezones — `toISOString()`
converts to UTC before slicing, so a local-constructed Date shifts a
day in offset zones. Use local calendar accessors
(getFullYear/getMonth/getDate). Validated end-to-end on a live SEA
warehouse under TZ=Australia/Sydney: a `new Date(2024,2,14)` now
round-trips as 2024-03-14 (was 2024-03-13). Regression test sabotages
toISOString so it guards in any timezone (incl. the UTC CI runner).
2. SeaOperationBackend.status() (sync path) could block indefinitely —
it gated Succeeded on `fetchHandlePromise` *existing*, but that is
assigned synchronously when getFetchHandle() is first called while
result() may still be pending; status() would then report Succeeded
early AND await the pending result() via readRichStatusFields(). Gate
on `blockingStatement` (set only after result() resolves) instead.
3. Async-path progress callback omitted the rich-status fields on the
terminal Succeeded tick (the sync path includes them) — parity break
for DML numModifiedRows. Merge the rich fields into the Succeeded
callback in waitUntilReadyAsync.
Also:
- KERNEL_REV -> 9c2e2378 (kernel main, databricks#144 merged). Binding contract
(native/sea/index.d.ts) already matched the bumped surface.
- prettier --write (lint fix) + new regression tests for findings 1-3.
Co-authored-by: Isaac
Signed-off-by: Madhavendra Rathore <madhavendra.rathore@databricks.com>
---------
Signed-off-by: Madhavendra Rathore <madhavendra.rathore@databricks.com>
0 commit comments