Skip to content

[coverage] Conformance findings: CONCURRENT-006 #467

Description

@peco-engineer-bot

Summary

Surfaced by the multi-language coverage fan-out while conformance-testing these SPEC-IDs against databricks/databricks-sql-go. 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-go) is fixed, then flips green as a tripwire.

Findings

  • CONCURRENT-006 [thrift]: Cancelling the query context does not unblock a result-batch fetch already parked inside a CloudFetch cloud-storage download: the fetch stays blocked for the full download (>10s past the interrupt, against a 30s injected delay) instead of racing the download against the cancelled context, so a consumer draining results on a background goroutine has no bounded teardown.
    • failing test: TestInterruptInFlightResultBatchFetch (see the coverage PR diff under tests/)

Reproduce & Expected

CONCURRENT-006 — Verify that a result-stream fetch that is BLOCKED inside a slow batch fetch can be interrupted from another thread, so the blocked fetch call returns PROMPTLY with a cancellation outcome instead of w…

Reproduce:

  • Each cloud-storage download stalls 30s, so the drain parks inside it.
  • Execute a query whose result is delivered via CloudFetch external links, and obtain
    the interrupt handle for its result stream while the stream is live.
  • Drain the result on a background thread/task. It blocks inside the delayed download.
  • Long enough that the background fetch is inside the delayed download.
  • Fire the result-stream interrupt from the main thread while the fetch is in flight,
    then fire it a SECOND time to exercise idempotency.
  • The parked fetch call must return; measure elapsed from the interrupt.
  • Fetch once more on the SAME result — must return promptly, no rows.
  • Close/dispose the result and release the interrupt handle (either order) after the
    cancel.

Expected (per the shared spec):

  • completes without an exception
  • result has exactly 0 row(s)
  • result has exactly 0 row(s)
  • completes without an exception
  • full assertion contract:
result:
- label: interrupt_fired
  no_exception: true
- label: interrupt_fired
  elapsed_seconds_range:
    max: 2
- label: fetch_interrupted
  elapsed_seconds_range:
    max: 10
- label: fetch_interrupted
  reports_cancellation: true
- label: fetch_interrupted
  row_count: 0
- label: repeat_fetch
  elapsed_seconds_range:
    max: 5
- label: repeat_fetch
  row_count: 0
- label: teardown
  no_exception: true

Context

Activity

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions