Skip to content

[KYUUBI #3356][SERVER] Add experimental Arrow Flight SQL frontend - #7624

Open
nryanov wants to merge 1 commit into
apache:masterfrom
nryanov:kyuubi-flight-sql
Open

[KYUUBI #3356][SERVER] Add experimental Arrow Flight SQL frontend#7624
nryanov wants to merge 1 commit into
apache:masterfrom
nryanov:kyuubi-flight-sql

Conversation

@nryanov

@nryanov nryanov commented Aug 11, 2026

Copy link
Copy Markdown

Previous existing PR was closed, but feature-request is still active :)

Why are the changes needed?

Add an experimental Arrow Flight SQL frontend so clients can run SQL and metadata operations through Kyuubi while reusing the existing session/engine lifecycle (Spark, Trino, Hive, JDBC, etc.). The producer is a transport adapter only: it calls BackendService and does not invoke engine APIs directly.

Main capabilities:

  • Enable via kyuubi.frontend.protocols=FLIGHT_SQL and configure with kyuubi.frontend.flight.sql.* keys (default bind port 10299).
  • Statement queries, catalogs/schemas/tables/table-types/type info, Arrow IPC streaming with bounded page fetch, cancellation/cleanup.
  • Auth: NONE, Basic/LDAP, Kerberos SPNEGO bootstrap with short-lived bearer tokens; TLS via PEM (optional keystore→PEM materialization).
  • HA: dedicated discovery namespace (kyuubi.ha.flight.sql.namespace), advertised Flight endpoint, node-affine tickets (no transparent mid-query failover).
  • Flight-specific metrics.

Out of scope / intentional limits:

  • Explicit unsupported Flight SQL paths (ingest, Substrait, transactions, full prepared-statement binding) return unimplemented status.

How was this patch tested?

  • Unit/integration tests under kyuubi-server:
    • KyuubiFlightSqlFrontendServiceSuite (lifecycle / protocol enablement)
    • KyuubiFlightSqlQuerySuite (execute + Arrow stream via Java FlightSqlClient; run with Slow tag enabled)
    • KyuubiFlightAuthHandlerSuite
    • KyuubiFlightArrowUtilsSuite
  • Shared harness: WithFlightSqlServer
  • Config/HA coverage: KyuubiConfSuite, HighAvailabilityConfSuite
  • Local docker tests

Was this patch authored or co-authored using generative AI tooling?

Yes. Assisted-by: Cursor Grok 4.5

### Why are the changes needed?

Add an experimental Arrow Flight SQL frontend so clients can run SQL and
metadata operations through Kyuubi while reusing the existing session/engine
lifecycle (Spark, Trino, Hive, JDBC, etc.). The producer is a transport
adapter only: it calls BackendService and does not invoke engine APIs
directly.

Main capabilities:

- Enable via `kyuubi.frontend.protocols=FLIGHT_SQL` and configure with
  `kyuubi.frontend.flight.sql.*` keys (default bind port `10299`).
- Statement queries, catalogs/schemas/tables/table-types/type info, Arrow
  IPC streaming with bounded page fetch, cancellation/cleanup.
- Auth: NONE, Basic/LDAP, Kerberos SPNEGO bootstrap with short-lived bearer
  tokens; TLS via PEM (optional keystore→PEM materialization).
- HA: dedicated discovery namespace (`kyuubi.ha.flight.sql.namespace`),
  advertised Flight endpoint, node-affine tickets (no transparent mid-query
  failover).
- Flight-specific metrics.

Out of scope / intentional limits:

- Not end-to-end zero-copy past the existing BackendService Thrift/TRowSet
  Arrow boundary.
- Explicit unsupported Flight SQL paths (ingest, Substrait, transactions,
  full prepared-statement binding) return unimplemented status.

### How was this patch tested?

- Unit/integration tests under `kyuubi-server`:
  - `KyuubiFlightSqlFrontendServiceSuite` (lifecycle / protocol enablement)
  - `KyuubiFlightSqlQuerySuite` (execute + Arrow stream via Java
    `FlightSqlClient`; run with Slow tag enabled)
  - `KyuubiFlightAuthHandlerSuite`
  - `KyuubiFlightArrowUtilsSuite`
- Shared harness: `WithFlightSqlServer`
- Config/HA coverage: `KyuubiConfSuite`, `HighAvailabilityConfSuite`
- Regenerated `docs/configuration/settings.md` via
  `dev/gen/gen_all_config_docs.sh`
- Spotless formatting on touched modules

### Was this patch authored or co-authored using generative AI tooling?

Yes. Assisted-by: Cursor

Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant