Özer Cem KELAHMETKELAHMET
Articles · Data governance

Data lineage with OpenLineage: run events, column lineage and impact analysis in practice

OpenLineage turns every pipeline run into a small JSON event that names its inputs, outputs and column mappings. This guide emits real events with the Python client, builds a column graph from them, and uses it to answer two governance questions: what breaks if a column changes, and where personal data flows unmasked.

Download Markdown
At a glance
Reading time
17 min
Sections
9
Code examples
3
Tables
4
Sources
9
Published
25 Nov 2026
In 30 seconds
What changed
OpenLineage 1.53.0 adds explicit lineage facets
Why it matters
Lineage is only as good as its coverage and its naming.
What to do
Pick a backend

Ask a data team which dashboards break if a source column changes type, and the honest answer is often "let us check". Lineage is the record that answers that question in seconds. It says which jobs read which datasets, which datasets they wrote, and, at the finest level, which output columns were computed from which input columns. Governance depends on it: you cannot prove that personal data stays masked, or assess the blast radius of a schema change, without knowing how data flows.

OpenLineage is the open standard most tools now use to capture that record. Instead of scanning code after the fact, each job emits small JSON events as it runs, describing its inputs, outputs and optional details called facets. Integrations exist for Airflow, Spark, dbt, Flink and others, and backends such as Marquez store and draw the resulting graph. The project ships often: version 1.53.0 on 1 September 2026 added explicit lineage facets to the specification, and 1.55.0 followed on 29 October 2026 with dbt Core v2 support.

This article builds lineage from the ground up. You will emit real OpenLineage events for a four-job bronze, silver and gold pipeline with the Python client, turn them into a column-level graph in about 40 lines of Python, and use it for impact analysis and a personal-data check. Every output shown was produced by running the code with openlineage-python 1.55.0. For the wider context of catalogs and lineage tools, see data lineage and data catalogs.

What happened

OpenLineage 1.53.0 adds explicit lineage facets (1 September 2026)

The 1.53.0 release notes list "Spec: Add explicit lineage facets": job and dataset facets for declaring relationships at the dataset, field and job level, "without Cartesian-product inference". In the Python client these appear as LineageDatasetFacet and LineageJobFacet. The same release added Python 3.14 and Spark 4.2 support and configurable retries for the GCP Lineage and GCS transports.

OpenLineage 1.55.0 adds dbt Core v2 support (29 October 2026)

According to its release notes, 1.55.0 supports dbt Core v2 by reading its OpenTelemetry output during runs, with breaking changes to dbt job naming. It also adds OAuth 2.0 client credentials to the Go client, an experimental read-only OData catalog integration, and fixes for Iceberg MERGE column lineage and nested Delta MERGE sources in Spark. On the storage side, Marquez, the reference backend, released 0.50.0 on 24 October.

The OpenLineage object model

OpenLineage describes the world with three nouns and one verb. Think of a factory logbook: each entry says which machine ran, when, which materials went in and which products came out.

  • Job. A process that consumes or produces datasets, identified by a unique name within a namespace. An Airflow task is named {dag_id}.{task_id}; a SQL job is {schema}.{table}.
  • Run. One execution of a job. The client generates a runId UUID and keeps it for all events of that run; the specification recommends UUIDv7, which sorts by time.
  • Dataset. A table, topic or file. Its name comes from its physical location, and namespace plus name should identify it uniquely across your data estate.
  • RunEvent. The verb: a state update sent when something significant happens to a run.

Naming matters more than it looks, because two events only connect in the graph if they name a dataset identically. The specification gives formats per store:

Table 1. The OpenLineage object model
Store Namespace Name
Postgres postgres://{host}:{port} {database}.{schema}.{table}
Snowflake snowflake://{organization name}-{account name} {database}.{schema}.{table}
BigQuery bigquery {project id}.{dataset name}.{table name}
S3 s3://{bucket name} {object key}
Kafka kafka://{bootstrap server host}:{port} {topic}
Unity Catalog unitycatalog://{host} {catalog}.{schema}.{table}

For Snowflake the page warns that the older account-locator namespace is still supported but produces IDs that do not match the newer format, so lineage nodes will not connect if you switch later. Pick one format and enforce it.

The run cycle

Each run sends a sequence of events. The eventType field takes six values:

Table 2. The run cycle
eventType Meaning
START The job began
RUNNING Extra information while it runs
COMPLETE Execution finished successfully (terminal)
FAIL The job failed (terminal)
ABORT The job stopped abnormally (terminal)
OTHER Extra metadata outside the normal cycle, even before START

A batch job sends START, optionally RUNNING, then one terminal state. After a terminal event, no more events are sent for that run. Streaming jobs usually send START and then a series of RUNNING events. Events for a run are cumulative, so an input may appear on START, on COMPLETE or on both.

Volume follows from this. A platform with 400 hourly batch jobs sending START and COMPLETE emits 400 × 24 × 2 = 19,200 events a day. In our example each event was 0.8 to 2.6 KB of JSON, so lineage is cheap to store compared with the data it describes, but you still want an asynchronous transport so that a slow lineage backend never slows a pipeline.

Facets carry the detail

The core event is deliberately thin. Detail lives in facets, named JSON objects attached to a run, job or dataset. Common ones are schema and dataSource on datasets, sql and parent on runs, sourceCodeLocation on jobs, dataQualityMetrics on inputs and outputStatistics on outputs. Because facets have published JSON schemas, a consumer can ignore facets it does not understand.

Column lineage: direct, indirect and masked

Dataset lineage tells you that gold.revenue_by_country reads silver.orders. Column lineage tells you that its revenue_eur column is a sum of silver.orders.amount_eur, and that silver.orders.customer_id only influences it through a join. That difference decides impact analysis: renaming amount_eur breaks the revenue number, while changing customer IDs can change which country a row lands in.

The columnLineage facet sits on an output dataset. Its fields map lists, for each output column, the input fields it depends on, each with one or more transformations:

Table 3. Column lineage: direct, indirect and masked
Type Subtype Meaning Example
DIRECT IDENTITY Copied unchanged SELECT id AS order_id
DIRECT TRANSFORMATION Computed from values in the same row amount * fx_rate
DIRECT AGGREGATION Computed across many rows SUM(amount_eur)
INDIRECT JOIN Used in a join condition ON o.customer_id = c.customer_id
INDIRECT GROUP_BY, FILTER, SORT, WINDOW Shapes which rows appear or their order WHERE status = 'paid'
INDIRECT CONDITIONAL Used in IF, CASE WHEN or COALESCE CASE WHEN country IS NULL ...

Each transformation can also carry masking: true when the operation obfuscates the input, such as hashing or counting. That flag turns lineage into a privacy tool: a path from a personal-data column to a gold table that passes through a masking step is acceptable, and a path with no masking step is a finding.

Inputs that affect the whole output rather than one column, such as an ORDER BY, go into a separate top-level dataset array. That keeps the facet compact. The OpenLineage docs note that the Spark integration's legacy mode, the default while spark.openlineage.columnLineage.datasetLineageEnabled is false, instead copies every dataset-level input into every output field, which is nearly a Cartesian product. The docs recommend enabling the option. The arithmetic shows why: for a query with one direct input per output column and 3 dataset-level inputs, the compact form holds n + 3 entries for n output columns, and the legacy form holds n + 3n.

Column lineage entries: compact versus legacy Spark form
compact (dataset array)legacy (copied into every field)
020040060080010 columns40 columns100 columns200 columnscompact (dataset array) · 10 columns: 1313compact (dataset array) · 40 columns: 4343compact (dataset array) · 100 columns: 103103compact (dataset array) · 200 columns: 203203legacy (copied into every field) · 10 columns: 4040legacy (copied into every field) · 40 columns: 160160legacy (copied into every field) · 100 columns: 400400legacy (copied into every field) · 200 columns: 800800output columns in the queryinput field entries
Figure 1. Computed in this article: one direct input per output column and 3 dataset-level indirect inputs, following the OpenLineage column lineage facet docs

Emitting events with the Python client

The example pipeline has two bronze tables, orders and customers, and four jobs. silver_customers hashes emails. silver_orders converts amounts to euros but copies billing_email through unchanged, a realistic mistake. gold_revenue_by_country joins and aggregates, and gold_order_contacts copies order IDs and emails for a support tool. The script writes events to a local file, so it runs without any server:

# openlineage-python 1.55.0; writes events to lineage.jsonl
from datetime import datetime, timezone
from openlineage.client import OpenLineageClient
from openlineage.client.transport.file import FileConfig, FileTransport
from openlineage.client.event_v2 import RunEvent, RunState, Run, Job, InputDataset, OutputDataset
from openlineage.client.facet_v2 import schema_dataset, column_lineage_dataset as cl
from openlineage.client.uuid import generate_new_uuid

client = OpenLineageClient(transport=FileTransport(
    FileConfig(log_file_path="lineage.jsonl", append=True)))
NS, PRODUCER = "postgres://warehouse:5432", "https://example.com/etl/v1"

def col(ds, field, t, sub, masking=False):
    return cl.InputField(namespace=NS, name=ds, field=field,
        transformations=[cl.Transformation(type=t, subtype=sub, masking=masking)])

def schema(*names):
    return schema_dataset.SchemaDatasetFacet(fields=[
        schema_dataset.SchemaDatasetFacetFields(name=n, type="VARCHAR") for n in names])

def run_job(job, inputs, output, out_cols, lineage):
    run, j = Run(runId=str(generate_new_uuid())), Job(namespace="etl", name=job)
    ins = [InputDataset(namespace=NS, name=i) for i in inputs]
    now = datetime.now(timezone.utc).isoformat()
    client.emit(RunEvent(eventType=RunState.START, eventTime=now, run=run, job=j,
                         producer=PRODUCER, inputs=ins))
    out = OutputDataset(namespace=NS, name=output, facets={
        "schema": schema(*out_cols),
        "columnLineage": cl.ColumnLineageDatasetFacet(
            fields={k: cl.Fields(inputFields=v) for k, v in lineage.items()})})
    client.emit(RunEvent(eventType=RunState.COMPLETE, eventTime=now, run=run, job=j,
                         producer=PRODUCER, inputs=ins, outputs=[out]))

run_job("silver_orders", ["shop.bronze.orders"], "shop.silver.orders",
        ["order_id", "customer_id", "amount_eur", "email"], {
    "order_id":    [col("shop.bronze.orders", "id", "DIRECT", "IDENTITY")],
    "customer_id": [col("shop.bronze.orders", "customer_id", "DIRECT", "IDENTITY")],
    "amount_eur":  [col("shop.bronze.orders", "amount", "DIRECT", "TRANSFORMATION"),
                    col("shop.bronze.orders", "currency", "DIRECT", "TRANSFORMATION")],
    "email":       [col("shop.bronze.orders", "billing_email", "DIRECT", "IDENTITY")]})
# silver_customers, gold_revenue_by_country and gold_order_contacts follow the same
# pattern; silver_customers marks email -> email_hash with masking=True, and the
# revenue job marks the customer_id join as INDIRECT/JOIN.

Running all four jobs writes 8 events, START and COMPLETE for each. The client adds a run facet recording its own version (1.55.0), and the generated run IDs are UUIDv7, as the specification recommends. In production you would swap the file transport for HTTP to Marquez or another backend, or Kafka for high volume; the event content stays the same.

Building the graph and asking questions

A lineage backend does this for you, but doing it once by hand shows what the graph really contains. The script reads COMPLETE events, turns every input field and transformation into an edge, then walks the graph:

import json
from collections import defaultdict, deque

edges = defaultdict(list)   # (dataset, column) -> [(downstream, type, subtype, masking)]
for line in open("lineage.jsonl"):
    ev = json.loads(line)
    if ev["eventType"] != "COMPLETE":
        continue
    for out in ev["outputs"]:
        for out_col, spec in out["facets"].get("columnLineage", {}).get("fields", {}).items():
            for f in spec["inputFields"]:
                for t in f.get("transformations", []):
                    edges[(f["name"], f["field"])].append(
                        ((out["name"], out_col), t["type"], t.get("subtype"), bool(t.get("masking"))))

def downstream(start, direct_only=False):
    seen, q = set(), deque([start])
    while q:
        for nxt, typ, _, _ in edges[q.popleft()]:
            if (not direct_only or typ == "DIRECT") and nxt not in seen:
                seen.add(nxt); q.append(nxt)
    return sorted(seen)

def unmasked_paths(start):
    hits, q = [], deque([(start, [start])])
    while q:
        node, path = q.popleft()
        for nxt, typ, _, masked in edges[node]:
            if typ == "DIRECT" and not masked:
                hits.append(path + [nxt]); q.append((nxt, path + [nxt]))
    return hits

print(downstream(("shop.bronze.orders", "customer_id")))
print(downstream(("shop.bronze.orders", "customer_id"), direct_only=True))
for pii in [("shop.bronze.customers", "email"), ("shop.bronze.orders", "billing_email")]:
    print(pii, unmasked_paths(pii))

The graph has 15 edges. The results:

  • Impact of bronze.orders.customer_id, all edges: silver.orders.customer_id and gold.revenue_by_country.country. Direct edges only: just silver.orders.customer_id. The country column depends on customer IDs only through the join, so a change there can move rows between countries without any column being renamed.
  • Unmasked paths from bronze.customers.email: none. Its only edge is the hashed email_hash, flagged masking: true.
  • Unmasked paths from bronze.orders.billing_email: two, silver.orders.email and then gold.order_contacts.email. Raw email reaches a gold table, and the lineage graph found it without anyone reading SQL.

The blast radius of every bronze column, counted as downstream columns reachable, shows how much indirect edges add:

Table 4. Building the graph and asking questions
Bronze column Downstream columns (all edges) Downstream columns (direct only)
customers.country 2 2
customers.email 1 1
customers.id 3 2
orders.amount 2 2
orders.billing_email 2 2
orders.currency 2 2
orders.customer_id 2 1
orders.id 2 2
Blast radius per bronze column
all edgesdirect edges only
0123customers.countryall edges · customers.country: 22direct edges only · customers.country: 22customers.emailall edges · customers.email: 11direct edges only · customers.email: 11customers.idall edges · customers.id: 33direct edges only · customers.id: 22orders.amountall edges · orders.amount: 22direct edges only · orders.amount: 22orders.billing_emailall edges · orders.billing_email: 22direct edges only · orders.billing_email: 22orders.currencyall edges · orders.currency: 22direct edges only · orders.currency: 22orders.customer_idall edges · orders.customer_id: 22direct edges only · orders.customer_id: 11orders.idall edges · orders.id: 22direct edges only · orders.id: 22downstream columns affected
Figure 2. Computed by running this article's lineage graph script on the 8 emitted OpenLineage events

The two columns where the numbers differ are the join keys. That is typical: join keys rarely appear in output values, yet they decide which rows meet. An impact tool that follows only direct edges will understate the risk of changing them.

Use cases and examples

Schema change review. A platform team requires every pull request that alters a bronze or silver table to include an impact report. A CI step queries the lineage backend for downstream columns of each changed column, separating direct from indirect edges as above, and posts the list with owning teams. A change to orders.customer_id lists the revenue country column as indirectly affected, so the analytics team reviews it before merge. This pairs naturally with data contract validation.

Personal-data audit for GDPR. A retailer tags source columns holding personal data and runs the unmasked-path search nightly against lineage from Spark and dbt. Any path from a tagged column to a gold or export table without a masking: true step opens a ticket. In the example, billing_email reaching gold.order_contacts would be flagged on the first run. Lineage only shows the flow; access controls such as those in Unity Catalog still decide who can read the table.

Incident root cause. A revenue dashboard drops 20% overnight. The on-call engineer opens the lineage graph for gold.revenue_by_country.revenue_eur, follows its direct edges upstream to bronze.orders.amount and currency, and checks the run events of silver_orders: the latest run sent FAIL after a partial write. Because each run carries its own run ID and time, the engineer can see which run produced the bad data and rerun it, the same replay discipline described in the medallion pipeline quality simulation.

Cross-tool lineage with change data capture. A bank streams Postgres changes through Debezium into Kafka, processes them in Spark and models them in dbt. Each tool emits OpenLineage with consistent naming: Debezium jobs as {topic.prefix}.{taskId}, Kafka topics as kafka://host:port plus topic. Because names match, the backend joins the hops into one graph from the source table to the dashboard. The CDC hop itself is described in CDC with Debezium and Kafka Connect.

What it means in practice

Lineage is only as good as its coverage and its naming. One job that emits nothing breaks the chain, and one tool that names a Snowflake table with a different namespace splits the graph in two. The practical work is enabling integrations everywhere data moves, Airflow, Spark, dbt, streaming jobs, and enforcing the naming conventions so nodes connect.

Column lineage is where governance value concentrates. Dataset edges answer "what reads this table", but impact analysis and privacy checks need column edges with their DIRECT and INDIRECT types and masking flags. Automatic integrations derive these from SQL and query plans. Hand-written jobs need you to emit them, as in the example, or to use the new explicit lineage facets from 1.53.0 to declare relationships directly. Storage is cheap, roughly 19,200 small events a day for 400 hourly jobs, so the cost is engineering attention, not infrastructure.

What to do now

  1. Pick a backend. Start with Marquez or a catalog that accepts OpenLineage events, such as those listed with AWS Glue Data Catalog or other data catalogs.
  2. Enable the orchestrator integration. In Airflow, install apache-airflow-providers-openlineage (version 2.21.1 lists Airflow 2.11.0 as its minimum) so every task emits events.
  3. Turn on Spark column lineage properly. Set spark.openlineage.columnLineage.datasetLineageEnabled=true to avoid the near-Cartesian legacy form.
  4. Fix naming early. Adopt the specification's namespace and name formats, especially the organization-account form for Snowflake.
  5. Instrument custom jobs. Emit START and terminal events with the Python client, including columnLineage with transformation types and masking flags.
  6. Use an asynchronous transport. Do not let a slow backend block pipelines; use HTTP with retries or Kafka for volume.
  7. Tag personal-data columns. Run an unmasked-path check on every lineage update and route findings to owners.
  8. Add impact reports to CI. For every schema change, list downstream columns, separating direct and indirect edges.
  9. Track coverage. Measure the share of jobs that emitted a COMPLETE or FAIL event in the last day, and chase the gaps.

Risks and open questions

Coverage gaps hide risk. A job without an integration, such as a script run from cron, leaves a hole. Impact queries then return incomplete answers that look complete.

Derived lineage can be wrong. SQL parsers miss dynamic SQL, user-defined functions and some engine features. The 1.55.0 release notes list fixes for Iceberg MERGE column lineage and nested Delta MERGE sources, a reminder that parser coverage keeps changing.

Masking flags depend on the producer. The specification says which operations count as masking depends on the source system, so a hash in one tool may not be flagged in another. Validate flags before trusting a privacy report.

Naming drift splits graphs. Switching Snowflake namespace formats, or two tools disagreeing on database names, silently disconnects nodes.

Breaking changes in integrations. The dbt Core v2 support in 1.55.0 comes with breaking changes to job naming, which can split history for the same model across two job names.

Watch next: adoption of the explicit lineage facets by integrations and backends, how dbt Core v2 lineage settles after the job naming change, and whether Spark's compact column lineage becomes the default, as the docs suggest it may.

Frequently asked questions

What is the difference between dataset and column lineage?

Dataset lineage records which jobs read and write which tables. Column lineage records which output columns come from which input columns and how, through identity copies, transformations, aggregations, joins or filters. Impact analysis and privacy checks need the column level.

Does OpenLineage store or display lineage?

No. OpenLineage is a specification plus client libraries and integrations that emit events. A backend such as Marquez, or a catalog that accepts OpenLineage events, stores them and draws the graph.

What do DIRECT and INDIRECT mean in column lineage?

DIRECT means the output value is derived from the input, by copying, transforming or aggregating it. INDIRECT means the input affects the output without being its source, for example as a join key, filter, grouping or sort column.

How much data does lineage generate?

A batch job usually sends two events per run, START and a terminal state. A platform with 400 hourly jobs produces about 19,200 events a day, each typically a few kilobytes of JSON (0.8 to 2.6 KB in this article's example), which is small next to the data the jobs process.

Can lineage prove personal data is protected?

It can show whether a path from a personal-data column to an output passes through a step flagged as masking. It cannot enforce access, and masking flags depend on each producer, so combine lineage checks with access controls and review.

Summary

OpenLineage records lineage as run events: each job run sends START and a terminal state naming its inputs, outputs and facets, with column lineage that marks every input field as DIRECT or INDIRECT and flags masking. We emitted 8 real events for a four-job pipeline with openlineage-python 1.55.0, built a 15-edge column graph, and found that a join key's blast radius doubles when indirect edges count and that raw billing emails reached a gold table unmasked. Recent releases added explicit lineage facets (1.53.0, 1 September 2026) and dbt Core v2 support (1.55.0, 29 October 2026). The work that makes lineage useful is coverage, consistent naming and column-level detail.

Sources

Cite this article

Kelahmet, Ö. C. (2026, November 25). Data lineage with OpenLineage: run events, column lineage and impact analysis in practice. Özer Cem KELAHMET. https://www.ozercemkelahmet.com/articles/openlineage-column-lineage-impact-analysis

BibTeX
@online{kelahmet2026openlineage,
  author = {Kelahmet, {\"O}zer Cem},
  title  = {{Data lineage with OpenLineage: run events, column lineage and impact analysis in practice}},
  year   = {2026},
  month  = {nov},
  url    = {https://www.ozercemkelahmet.com/articles/openlineage-column-lineage-impact-analysis}
}
Version historyfirst version
  1. Published

Factual corrections are listed here with what changed. Wording and formatting edits are not listed.

Last updated Nov 25, 2026
Type to search.
    ↑↓ navigate↵ open