Skip to main content

faucet_source_databricks/
lib.rs

1#![cfg_attr(docsrs, feature(doc_cfg))]
2
3//! # faucet-source-databricks
4//!
5//! Databricks SQL query source for the [`faucet-stream`](https://crates.io/crates/faucet-stream)
6//! ecosystem. Runs a SQL statement against a Databricks **SQL Warehouse** via
7//! the [Statement Execution API](https://docs.databricks.com/api/workspace/statementexecution)
8//! (plain REST — no JDBC/ODBC driver) and streams the result rows as typed
9//! JSON objects.
10//!
11//! This is the **query-results** read path for Databricks (joins / aggregates /
12//! filtered extracts). For full-table lakehouse scans and the write path, use
13//! the Delta Lake connectors (`faucet-source-delta` / `faucet-sink-delta`).
14//!
15//! - Async statement lifecycle: submit → poll until terminal → stream result
16//!   chunks (INLINE + `JSON_ARRAY`), following `next_chunk_internal_link`.
17//! - Type-aware decode from the response `manifest` column schema.
18//! - Incremental replication via a bookmark column + a `${bookmark}` token
19//!   (server-side named param) plus a client-side filter backstop.
20//! - Bearer auth (PAT / OAuth M2M), inline or via the shared `auth:` catalog.
21
22mod config;
23mod convert;
24mod stream;
25
26pub use config::{DatabricksAuth, DatabricksParam, DatabricksReplication, DatabricksSourceConfig};
27pub use stream::DatabricksSource;