Skip to content

Fixes 28492: Add a dashboard pipeline option to skip direct chart lineage - #38448

Merged
IceS2 merged 8 commits into
open-metadata:mainfrom
Vamsi-klu:feat/28492-looker-chart-lineage
Nov 26, 2026
Merged

IceS2 merged 8 commits into
open-metadata:mainfrom
Vamsi-klu:feat/28492-looker-chart-lineage

Conversation

@Vamsi-klu

@Vamsi-klu Vamsi-klu commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Describe your changes

Fixes #28492

Dashboard metadata pipelines can now turn off direct chart lineage with Include Direct Chart Lineage. It defaults to true, so existing pipelines keep their lineage. With it off, Looker skips the Explore → Chart edges and Metabase skips the Table → Chart edges, and neither connector looks the charts up for that lineage. Lineage from those sources to the dashboard and the shared Dashboard → Chart edges are still written, so each chart stays connected to its sources through its dashboard.

Type of change

  • New feature

High-level design

DashboardServiceMetadataPipeline owns the optional includeDirectChartLineage property. Connectors read it through DashboardServiceSource.include_direct_chart_lineage, which treats only an explicit false as off, so an omitted value or a null keeps the default. Looker returns before its chart loop. Metabase skips _get_chart_entity on both the query-builder and native SQL paths. yield_dashboard_chart_lineage does not read the option.

An earlier revision put this on the Looker connection. Review moved it to the pipeline so every connector that draws direct chart lineage shares one setting and each pipeline can choose. Looker and Metabase are the only dashboard connectors that draw it today. The optional property needs no migration. An older ingestion worker rejects any workflow that carries it, and the UI form writes the default true into every dashboard pipeline it saves, so upgrade workers before saving dashboard pipelines. Workers already have to match the server's major and minor version, so this matters for a worker on an earlier patch of the same minor, or after a downgrade. Decision record

Tests

Use cases covered

  • Looker and Metabase with the option omitted, true, false and null. Metabase covers query-builder and native SQL cards.
  • Disabled runs make zero catalog Chart lookups for direct lineage, counted at OpenMetadata.get_by_name, and still write the source → dashboard edge.
  • Looker with two charts on the same Explore, a missing dashboard, and an invalid option value.
  • The shared Dashboard → Chart stage still writes one edge per chart for Looker and Metabase sources with the option off.

Unit tests

  • make unit_ingestion ARGS='-n 0 tests/unit/topology/dashboard/test_looker_chart_lineage.py tests/unit/topology/dashboard/test_dashboard_chart_lineage.py tests/unit/topology/dashboard/test_metabase.py': 65 passed.
  • With the schema and tests from this branch and the connector files from main, exactly the four disabled cases failed: Looker's option test and missing-dashboard case, and Metabase's query-builder and native SQL cases. The other 13 selected cases passed.
  • yarn test src/utils/IngestionWorkflowUtils.test.ts: 14 passed against the regenerated ingestion schemas.
  • Python model generation, json2ts-generate-all.sh and yarn parse-schema changed only the dashboard pipeline schema and the five generated types that embed it. Ruff format and lint passed on the changed Python files.

Backend tests

No Java source changes. The focused make java_affected plan selected no runnable tests. Its full plan, CreateIngestionPipelineImplTest and the ingestion-pipeline ITs, has not been run locally and is deferred to the merge queue.

Ingestion integration tests

There is no Looker or Metabase integration fixture in the repository and no live tenant in this run. The unit suites drive the real connector code with synthetic dashboards and a faked catalog boundary.

Playwright (UI) tests

No UI code changes. The toggle renders from the generated dashboardServiceMetadataPipeline schema alongside the other dashboard pipeline toggles. The connection-form Playwright case from the earlier revision was removed with the connection setting.

Manual test steps

Add or edit a dashboard metadata ingestion for Looker or Metabase, switch Include Direct Chart Lineage off and deploy. After the run, charts have no direct edge from their Explore or table, and the dashboard still has its upstream lineage and its Dashboard → Chart edges.

UI screen recording

The earlier recording showed the Looker connection setting that this revision removes, so I took it out. The new toggle is generated from the pipeline schema and needs no UI code.

Checklist

  • I have read the contributing guidelines.
  • My PR title follows Fixes <issue-number>: <short explanation>.
  • My PR links the issue above.
  • The schema adds an optional pipeline setting and needs no database migration.
  • I added ingestion tests for both connectors and the shared Dashboard → Chart stage.
  • I reviewed the change against REVIEW.md.
  • The decision record documents the setting and compatibility.
  • I updated the dashboard ingestion help text and the Looker and Metabase workflow examples.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no actionable issues were found.

Summary

Adds optional includeChartLineage to Looker connections, with a default of true.

  • Looker connections can keep charts linked through dashboards without direct Explore edges.

No actionable issues found. No tests were run during this review.

Acknowledged by Vamsi-klu: historical edges follow the existing override policy; older clients require the documented deployment and downgrade order; live Looker validation remains pending.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  E[Looker Explore] --> D[Dashboard]
  D --> C[Chart]
  E --> G{includeChartLineage is false?}
  G -->|No| C
  G -->|Yes| S[Skip direct edge and chart lookup]
Loading

Reviews (1) · Last reviewed commit: "Stabilize Looker connection persistence ..." · Reviewed by Greptile

@Vamsi-klu
Vamsi-klu marked this pull request as ready for review November 23, 2026 10:28
@Vamsi-klu
Vamsi-klu requested review from a team as code owners November 23, 2026 10:28
@github-actions

Copy link
Copy Markdown
Contributor

❌ PR checklist incomplete

This PR cannot be merged until the following are addressed on its linked issue:

The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically.

Maintainers can bypass this check by adding the skip-pr-checks label.

@github-actions

github-actions Bot commented Nov 25, 2026 •

Copy link
Copy Markdown
Contributor

UI browser tests

Ran: all test files (no impact map from main yet)

Result: ✅ 1099 passed · 154 skipped

@IceS2 IceS2 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we move this to DashboardServiceMetadataPipeline as includeDirectChartLineage, defaulting to true?

Looker emits Explore → Chart and Metabase emits Table → Chart, so both can use the same per-pipeline option.

With it off, skip the direct chart lookups and edge writes while preserving upstream lineage to the dashboard and the shared Dashboard → Chart edges.

Could we cover both connectors and assert that the disabled path makes zero catalog chart lookups for direct lineage?

Review asked for a single per-pipeline option instead of a Looker
connection setting, so every connector that draws lineage straight to a
chart reads the same flag.

- Add includeDirectChartLineage (default true) to
  DashboardServiceMetadataPipeline. Drop includeChartLineage from the
  Looker connection along with its generated types, help text, IT,
  Playwright case and form tests.
- Read it through DashboardServiceSource.include_direct_chart_lineage.
  Only an explicit false turns it off.
- Looker skips the Explore -> Chart lookups and edges. Metabase skips
  the Table -> Chart lookups and edges for query-builder and native SQL
  cards. Lineage to the dashboard and the Dashboard -> Chart stage are
  unchanged.
- Replace the unmerged Looker record with
  ADR:2026-11-25-direct-chart-lineage-is-a-dashboard-pipeline-option.
@Vamsi-klu Vamsi-klu changed the title Fixes 28492: Add a Looker chart lineage opt-out Fixes 28492: Add a dashboard pipeline option to skip direct chart lineage Nov 25, 2026
@Vamsi-klu

Copy link
Copy Markdown
Contributor Author

@IceS2 thanks, that's a better home for it. It now lives on DashboardServiceMetadataPipeline as includeDirectChartLineage and defaults to true. I dropped the Looker connection setting along with its generated types, help text, IT and Playwright case.

Both connectors read it through a small include_direct_chart_lineage property on DashboardServiceSource. Only an explicit false turns it off, so a null keeps the default. With it off:

  • Looker returns before the Explore → Chart loop, so it never looks a chart up.
  • Metabase skips _get_chart_entity on both the query-builder and the native SQL paths.
  • Table/Explore → Dashboard lineage is unchanged, and yield_dashboard_chart_lineage doesn't read the flag, so the shared Dashboard → Chart edges stay.

For tests, Looker and Metabase each run omitted / true / false / null, and Metabase does that for both card types. The disabled cases count Chart lookups at OpenMetadata.get_by_name and assert zero, while the dashboard edge is still written. I also added a case to test_dashboard_chart_lineage.py that runs the shared stage for Looker and Metabase sources with the flag off. To make sure the tests bite, I ran them against main's connector code: the four disabled cases fail and everything else passes. On the branch, all 65 pass.

I replaced the Looker decision record with one for the pipeline option and took the old connection-form recording out of the description, since it no longer applies. One related detail is now in the pipeline help text: direct edges from earlier runs stay unless overrideLineage is on, in which case the next Dashboard → Chart write replaces them.

IceS2 and others added 2 commits November 25, 2026 14:46
The UI form fills in schema defaults, so every dashboard pipeline it saves
carries includeDirectChartLineage, not only pipelines that turn it off.
State that, and that workers already match the server's major and minor
version, in the decision record.
@Vamsi-klu

Copy link
Copy Markdown
Contributor Author

Thanks. The risk note is right, and it reaches further than the PR said. The ingestion form fills in schema defaults, so every dashboard pipeline saved from the UI carries includeDirectChartLineage: true, not only the ones that switch it off. An older worker rejects any of them.

Workers already have to match the server's major and minor version (validate_versions), so the exposure is a worker on an earlier patch of the same minor, or a downgrade. Every defaulted pipeline option had the same compatibility when it was added, so I kept the schema as it is rather than special-casing this one.

0f5c36d corrects the decision record: upgrade the workers before saving dashboard pipelines, and remove the property from pipelines saved since the upgrade before downgrading. The PR description now says the same.

@gitar-bot

gitar-bot Bot commented Nov 26, 2026

Copy link
Copy Markdown
Code Review ✅ Approved 🟡 Medium risk

The pipeline option skips direct Looker and Metabase chart edges, which could alter lineage views that rely on direct source-to-chart relationships.

Adds an optional Include Direct Chart Lineage setting to dashboard metadata pipelines, defaulting to true, so Looker and Metabase can skip direct Explore → Chart and Table → Chart edges and chart lookups while keeping dashboard-level lineage. No issues found.

Verification

Rules No rules evaluated

Functional validation Not enabled

Set up

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Options

Display: compact → Showing compact verification results.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source

@IceS2
IceS2 merged commit 51731c5 into open-metadata:main Nov 26, 2026
45 of 46 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Add includeChartLineage config flag to Looker connector

3 participants