Databricks
Configuration reference for the Databricks metadata source: supported stages, source options, required Unity Catalog/Hive Metastore grants, and troubleshooting.
Databricks is supported as a metadata source. A spec.type: metadata pipeline introspects a Databricks workspace through its SQL warehouse and publishes source context into the DataOS metadata catalog without copying any table rows. The same service_type: databricks works for both classic and Unity Catalog deployments, Nilus reads the catalog topology from the workspace.
For batch row movement out of Databricks, see the Databricks. For the field-by-field authoring contract, see Metadata pipeline config.
Metadata stages
service_type: databricks supports the full DAG. The required mode field decides how much of it runs: shallow runs metadata + lineage; deep adds profiler, classification, and usage. Source inventory (metadata) runs first; once it succeeds, the remaining stages run in parallel.
metadata
shallow, deep
Catalogs, schemas, tables, views, and columns across the Unity Catalog or Hive Metastore topology.
lineage
shallow, deep
Asset and column lineage parsed from view definitions and query history.
profiler
deep
Per-column statistics (row counts, null counts, distinct counts, min/max, basic distributions).
classification
deep
Auto-classification tags applied to columns (PII heuristics).
usage
deep
Query history and popularity, which datasets are queried, when, and by what kinds of queries.
The first successful run establishes the source inventory and lineage; in deep, profiles, classification, and usage then deepen it. A frequent shallow pipeline keeps inventory and lineage fresh; pair it with a less frequent deep pipeline for the full profile.
Source options
Metadata pipelines accept only the customer-facing source.options keys below. Do not set source_table, Nilus assigns a stage-specific value to each DAG node internally.
service_type
Yes
all
Must be databricks.
database_filter
No
metadata
Optional include/exclude regexes against Unity Catalog catalog names. It is honoured for inventory only when ?catalog= is omitted. With ?catalog= set, inventory stays on that catalog.
schema_filter
No
all
Restrict by schema name. Same shape as database_filter.
table_filter
No
all
Restrict by table / view name. Same shape as database_filter.
query_log_duration
No
lineage, usage
Days of query history to ingest per run. Defaults to 1. Used by lineage (both modes) and usage (deep only).
result_limit
No
lineage, usage
Maximum number of query-history rows to fetch per run. Defaults to 10000000. Used by lineage (both modes) and usage (deep only).
mode (shallow or deep) is a required spec field, not a source.options key. See Metadata pipeline config: choosing a mode.
Required permissions
A metadata pipeline connects through a Databricks SQL warehouse and needs the token principal to be able to read the catalog/schema/table topology in scope:
the SQL warehouse must be running, or autostart must be enabled;
for Unity Catalog, grant
USE CATALOG,USE SCHEMA, and table-level read on the objects in scope;for lineage and usage, the principal needs access to the workspace query history surfaces.
For Hive Metastore (non-Unity-Catalog) deployments, drop the catalog-level grants and grant read on the database directly.
Sample Nilus config
Databricks metadata connects through a direct databricks:// URI with a projected access token (there is no DataOS depot variant for Databricks). Because spec.type is metadata, Nilus adds the internal metadata+ routing prefix automatically:
With mode: deep, this resource produces a five-node DAG (metadata root → lineage, profiler, classification, usage). Switch to mode: shallow for a 2-node metadata + lineage DAG. ?catalog=main binds inventory to that catalog, so database_filter is redundant here. Omit catalog if you want database_filter to choose which catalogs to inventory. For more ready-to-edit examples, see Metadata sample configs.
Behavior and capabilities
Connection: Databricks metadata connects only through a direct
databricks://...URI with a projected access token; there is no DataOS depot variant for Databricks. Nilus adds the internalmetadata+routing prefix fromspec.type: metadata. The URI carries the workspace host and HTTP path; project the access token throughspec.use.projectionand reference it as a{ENV_VAR}placeholder rather than inlining it. Authentication uses Databricks personal access tokens (PAT) or OAuth M2M.Bound catalog vs filter:
?catalog=is the equivalent of a bound database. When it is set, inventory stays on that catalog and adatabase_filternaming a different catalog is ignored. When it is omitted,database_filterdrives discovery; an unfiltered run inventories every catalog the token can reach, including Databrickssystemandsamples. A multi-entry filter is honoured for every named catalog.Compute target: Nilus connects to a SQL warehouse, not a notebook or all-purpose cluster. Use a small dedicated warehouse for metadata runs.
Scope discipline: omit
?catalog=only when you intend a multi-catalog inventory, and then setdatabase_filter. Otherwise bindcatalogand useschema_filter/table_filter.
Troubleshooting
400 Invalid token / 401 Unauthorized
Access token expired, revoked, or scoped to a different workspace.
Rotate the PAT or refresh the OAuth M2M token; confirm the workspace host matches the token.
Cluster is not running and autostart is not enabled
The SQL warehouse is stopped.
Turn on auto-start for the SQL warehouse, or start it before the scheduled run.
Inventory lands but lineage/usage are empty
The principal can read tables but not query history.
Grant the principal access to workspace query history.
A stage runs for hours
The extraction scope is unbounded.
Bind ?catalog= or set database_filter; tighten schema_filter / table_filter.
Datasets appear twice in search
One pipeline uses :443 on the host and another omits the port.
Standardise on one URI form. Delete the extra source if you already forked it.
database_filter named a catalog that never appeared
?catalog= is also set, so the bound catalog wins.
Omit catalog if the filter should drive inventory.
Related docs
Databricks: batch row movement out of Databricks.
Metadata sources: all metadata-capable sources and how to scope extraction.
Metadata pipelines: the conceptual model.
Metadata pipeline config: the
spec.type: metadatacontract and DAG anatomy.Metadata sample configs: ready-to-edit YAML.
Last updated
Was this helpful?