Repository navigation
Closed
Description
Summary
Surfaced by the multi-language coverage fan-out while conformance-testing these SPEC-IDs against databricks/databricks-sql-nodejs. Each finding is committed as an expected-failure (xfail) test in the coverage PR — the test asserts the CORRECT (post-fix) behavior and stays red until THIS driver (databricks/databricks-sql-nodejs) is fixed, then flips green as a tripwire.
Findings
- AUTH-219301 [thrift]: Thrift leaks one socket descriptor per closed DBSQLClient (OAuth M2M and PAT alike): 20 open/query/close cycles grow /proc/self/fd by 20, 1:1 with the cycle count, while a harness-only control phase stays flat; same symptom as ES-2348909.
- failing test:
OAuth session close releases auth resources — 20 open/query/close cycles do not grow the process descriptor count [thrift](see the coverage PR diff undertests/)
- failing test:
- AUTH-219301: Thrift path leaks one socket descriptor per CLOSED DBSQLClient, on the OAuth M2M and PAT paths alike: 20 open/query/close cycles grow /proc/self/fd by 20 (1:1 with the cycle count) while a harness-only control phase stays flat at +0, so a host that opens a connection per request eventually hits "Too many open files"; same symptom as ES-2348909. The SEA/kernel path releases correctly (+5/+7, independent of the cycle count).
Reproduce & Expected
AUTH-219301 — Closing an OAuth-authenticated connection must release everything that connection's authentication path allocated — the auth HTTP client, its auth provider, and the sockets, event-loop descriptors an…
Reproduce:
SELECT 1 AS test_value
SELECT 1 AS test_value
SELECT 1 AS test_value
SELECT 1 AS test_value
SELECT CURRENT_USER() AS userExpected (per the shared spec):
- completes without an exception
- completes without an exception
- completes without an exception
- result has exactly 1 row(s)
- [thrift] exactly 20
OpenSessioncall(s) - [sea] exactly 20
CreateSessioncall(s) - full assertion contract:
result:
- label: pat_control
no_exception: true
- label: oauth_cycles
no_exception: true
- label: pat_control
process_resource_growth:
metric: open_file_descriptors
baseline: pat_baseline
after: pat_after
max: 10
- label: oauth_cycles
process_resource_growth:
metric: open_file_descriptors
baseline: oauth_baseline
after: oauth_after
max: 10
- label: oauth_cycles
oauth_token_calls:
min: 20
- label: after_cycles
no_exception: true
- label: after_cycles
row_count: 1
protocol:
thrift:
- label: oauth_cycles
call_count:
method: OpenSession
expected: 20
sea:
- label: oauth_cycles
call_count:
operation: CreateSession
expected: 20Context
- The behavior was first fixed in a DIFFERENT driver — reference PR: fix(auth): hold the HTTP client weakly in OAuth providers databricks-sql-kernel#435 — which seeded the shared language-neutral spec. This issue tracks the same conformance gap in databricks/databricks-sql-nodejs; the reference PR is for cross-referencing the intended behavior, NOT a change to this repo.
- Coverage PR carrying the reproducing xfail test(s): https://github.com/databricks/databricks-driver-test/pull/2197
Metadata
Metadata
Assignees
Labels
No labels
Activity