Repository navigation
Breaking changes
- The module path is now
github.com/databricks/databricks-sql-go/v2. Add/v2to driver and subpackage imports. - Upgrade Apache Arrow Go from v12 to v18.8.0 (
github.com/apache/arrow-go/v18). The publicrows.ArrowBatchIteratornow uses v18arrow.RecordBatchand*arrow.Schema; update Arrow imports and code that uses batches.
Driver changes
- Fix HTTP connection leaks after failed requests or exhausted retries. Remove the MPL-2.0
go-retryablehttpandgo-cleanhttpdependencies (#177). - Cap OAuth M2M token requests at 60 seconds and retry failures according to
WithRetries, preventing indefinite hangs (#475). - Top-level GEOMETRY and GEOGRAPHY type names now include SRIDs, such as
GEOMETRY(0),GEOGRAPHY(4326)orGEOMETRY(ANY), in both string mode andWithEnableGeoSpatialSupport(true)mode. Match the family before(when choosing a decoder. Values and scan types are unchanged; Thrift still reportsSTRINGwithout a readable Arrow schema (#474). - Render non-finite FLOAT / DOUBLE values and MAP keys inside ARRAY / MAP / STRUCT results as JSON strings
"NaN","Infinity"and"-Infinity"on both backends. This fixes Thrift row-iteration errors and changes kernel MAP keys from"+Inf"/"-Inf". SQL NULL remainsnull; top-level floats remain numeric (#573). - Report declared DECIMAL precision and scale through
sql.ColumnType.DecimalSize()on both backends, including empty results (#500). - Return Arrow TIME values as UTC
time.Timeon0001-01-01, preserving precision and using clock-only nested JSON. Both backends now reportTIME/time.Timewith no length, including empty and NULL-only results, replacing Thrift'sSTRING/stringand SEA's empty type name/*interface{}(#505). - Top-level VARIANT columns now report
VARIANTinstead ofSTRINGfromsql.ColumnType.DatabaseTypeName(). Values remain JSON text with scan typestringand unchanged length. Thrift still reportsSTRINGwithout a server-supplied Arrow schema (#576). - Explicit
WithMaxDownloadThreads/maxDownloadThreadssettings now also control kernel buffering, affecting memory use and throughput. Unset defaults remain 10 for Thrift and 16 for the kernel; explicit kernel chunk settings take precedence. Zero or negative values warn and use 10, fixing CloudFetch EOF errors (#439). - Retry Thrift
ExecuteStatementaccording toWithRetriesonly when a connection to the server or proxy cannot be opened, before the statement is sent. Failures after connecting are still not retried. With default settings, a refused connection now fails after about 15 seconds (#423). - After
Close, rawdriver.Conncalls toPrepare,PrepareContext,ExecContextandQueryContextnow immediately returndriver.ErrBadConn("connection is closed").database/sqlusers are unaffected (#521). - Reject DSN
timeoutvalues outside ±9223372036 seconds instead of silently overflowingtime.Duration. Negative values within range remain valid (#490). - Avoid redundant Thrift result fetches when direct results specify
hasMoreRows=false(#539). - Add
statement_type=SQLand the result delivery format (INLINE_ARROW,EXTERNAL_LINKSorCOLUMNAR_INLINE, when known) to Thrift statement telemetry (#454). - Fix the module-root package conflict when building, linting or running Gazelle with the
toolsbuild tag (#162).
SQL kernel v1.5.0
Upgrade the kernel bindings to v1.5.0 with these changes for the kernel backend:
- Fix CloudFetch prefetching across result pages, share in-flight page requests, honor cancellation and return cached final chunks before EOF.
- Fetch all inline result pages with
WithCloudFetch(false)/useCloudFetch=false. This option overrides conflicting session settings and survives automatic backend recovery. Servers without paged inline support return a configuration error instead of downloading from cloud storage. - Release transport, HTTP client and runtime resources on session close, including resources retained by OAuth providers.
- Authenticate once before resolving feature flags; fail session open immediately if OAuth token retrieval fails.
- Fail TLS certificate verification errors after one attempt and report the underlying cause, including CloudFetch downloads.
- Omit signed URL query strings and signatures from CloudFetch errors and debug logs.
- Avoid redundant telemetry flush tasks during event bursts.
- Update Rust Arrow to 59.3.2 and QUIC dependencies for security fixes.