elastic / elastic/observability-migration-platform
Retire the bespoke YAML->NDJSON compile path once native Dashboards API coverage is proven
- Dominant language
- Python
- Stars
- 6
- Forks
- 8
- Avg merge
- 2d 22h
- Merged PRs (30d)
- 23
Description
## Background
#203 asked for the engine to adopt a dashboards-as-code IR and retire the bespoke Lens YAML -> NDJSON conversion path. PR #278 introduces the `NativeDashboard`/`NativePanel`/`NativeSection`/`NativeControl` IR and makes it the canonical path for native Dashboards API uploads (100%/100% typed-API acceptance on a 20/30 live Grafana/Datadog batch after two correctness fixes).
However, per review on #278, that PR does not fully close #203 as written: `kb-dashboard-cli` YAML compile still runs unconditionally for every Grafana dashboard, `obs-migrate compile` is unchanged, and the YAML -> NDJSON path remains an active fallback (used when the typed API rejects a native payload) rather than being retired.
## Proposal
Track the remaining retirement work separately from #278:
- Stop always running `kb-dashboard-cli` compile ahead of upload; only compile YAML -> NDJSON on demand, when the native typed-API upload for a given dashboard is rejected (i.e. make the legacy compile+import path lazy/fallback-only instead of unconditional).
- Once native-API coverage is proven wide enough in production (fallback essentially never exercised across the benchmark corpus), evaluate fully removing the YAML -> NDJSON compile path and `obs-migrate compile` command, or clearly re-scoping them as a debug/legacy-only surface.
- Re-validate success criteria from #203 against whatever is left: no fidelity regression (benchmark scorecard), no change to user-facing CLI/outputs/reports.
## Relationship to other issues
- Follows up on #203, whose "bespoke YAML->NDJSON conversion is retired" success criterion is not yet met.
- Split out from review discussion on #278, which lands the native IR as the canonical path but intentionally keeps YAML/`kb-dashboard-cli` as a fallback per this repo's "degrade gracefully" rule.
Contributor guide
Assessment
This issue has not been assessed yet.