Skip to content

Propagate OpenLineage context to Databricks job runs - #71770

Draft
mobuchowski wants to merge 2 commits into
apache:mainfrom
mobuchowski:databricks-openlineage-context-job-parameters
Draft

Propagate OpenLineage context to Databricks job runs#71770
mobuchowski wants to merge 2 commits into
apache:mainfrom
mobuchowski:databricks-openlineage-context-job-parameters

Conversation

@mobuchowski

@mobuchowski mobuchowski commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Existing Databricks jobs triggered by Airflow need the Airflow task hierarchy at run time so downstream OpenLineage events can retain parent and root relationships.

This change follows established implementations rather than introducing a new lineage format:

  • Airflow already injects OpenLineage Spark configuration for DatabricksSubmitRunOperator in #67894.
  • Airflow already forwards Dag params through Databricks CreateJobs, SubmitRun, and RunNow operators in #66613.
  • OpenLineage standardized the extensible parent context payload and job-type facets in OpenLineage #4682.

This PR composes those patterns:

  • DatabricksRunNowOperator injects the standardized context through the OPENLINEAGE_CONTEXT job parameter.
  • DatabricksSubmitRunOperator injects the same context into supported dict-shaped task parameters while retaining its existing new_cluster.spark_conf injection.
  • Existing context and incompatible positional parameter slots are preserved safely.
  • OpenLineage supported-operator documentation and regression tests cover both paths.

Validation:

  • prek pre-commit checks: passed
  • Available manual prek checks: passed
  • Provider mypy and focused Breeze tests: blocked before analysis because the local Podman/Docker backend was unavailable

Was generative AI tooling used to co-author this PR?
  • Yes — Codex (GPT-5.6)

Generated-by: Codex (GPT-5.6) following the guidelines


Drafted-by: Codex (GPT-5.6) (no human review before posting)

Existing Databricks jobs need the Airflow task hierarchy at run time so their downstream OpenLineage events can retain parent and root relationships.
Databricks submit runs need the same parent-run context as run-now jobs while retaining Spark configuration injection for workloads that support it.
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