Skip to content

[coverage] Conformance findings: STATEMENT-022 #472

Closed as not planned
Closed as not planned

Description

@peco-engineer-bot

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

  • STATEMENT-022 [thrift]: Thrift does not deduplicate concurrent Operation.cancel() calls: three simultaneous cancels send three CancelOperation RPCs instead of the single deduped RPC the reference driver sends
    • failing test: STATEMENT-022 — three simultaneous cancel() calls: no deadlock, dedup per protocol [thrift] (see the coverage PR diff under tests/)

Reproduce & Expected

STATEMENT-022 — Validates driver handles multiple threads calling CancelOperation on same statement without deadlock or crash.

Reproduce:

SELECT a.*, b.* FROM main.tpcds_sf1_delta.catalog_returns a CROSS JOIN range(1, 10000) b ORDER BY a.cr_order_number, b.id

Expected (per the shared spec):

  • completes without an exception
  • [thrift] exactly 1 CancelOperation call(s)
  • [sea] between 1 and 3 CancelStatement call(s)

Context

Activity

  1. added
    bugSomething isn't working
    engineer-botMaintainer-only: triggers the autonomous engineer-bot (bug-fix author on issues; follow-up on PRs)
    on Nov 5, 2026
  2. peco-engineer-bot commented on Nov 5, 2026

    @peco-engineer-bot
    ContributorAuthor

    🤖 engineer-bot produced a fix but could not open the PR (push or PR creation failed). See the workflow run for details.

  3. peco-engineer-bot commented on Nov 5, 2026

    @peco-engineer-bot
    ContributorAuthor

    🤖 engineer-bot opened a fix PR: #564

    Review before merge.

  4. vuanhphung commented on Nov 5, 2026

    @vuanhphung
    Collaborator

    Closing as not a bug.

    STATEMENT-022's goal is that concurrent cancel() calls don't deadlock or crash. The spec notes in specs/statement-execution.yaml say: "The primary goal is testing that multiple Cancel() calls don't cause deadlock or crash." The Node.js driver already does this: three concurrent cancels on Thrift all complete. The only mismatch reported here is the number of RPCs.

    The Thrift CancelOperation expected: 1 assertion just copies the C# driver's client-side dedup. The server handles repeated CancelOperation calls fine, and other drivers already pass while sending more than one:

    • JDBC asserts 1..3 cancel RPCs on both backends ("JDBC does not deduplicate them").
    • Python asserts at least 1; its Thrift recording has three CancelOperation calls.
    • SEA allows 1..3 for every driver.

    Also, the cited reference (databricks/databricks-sql-go#419) only tags telemetry errors; it doesn't dedup cancels.

    The fix in #564 grew into a cancel/close lifecycle change. For example, close() would skip CloseOperation when it overlapped a successful cancel. That isn't worth the risk for a gap that only concerns the RPC count, so #564 is closed too. The right fix is in the spec: relax the Thrift assertion to 1..3 and set nodejs/thrift back to implemented (databricks/databricks-driver-test#1015).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingengineer-botMaintainer-only: triggers the autonomous engineer-bot (bug-fix author on issues; follow-up on PRs)

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions