mirror of
https://github.com/openobserve/openobserve.git
synced 2026-11-04 00:08:55 +00:00
## What Makes the per-run test dashboards **live**. Adds non-fatal `report_to_openobserve` jobs that emit **one retry-aware run-summary doc per run** to OpenObserve, following the metrics work merged earlier (regression/docgen/council). Companion PR in the other repo mirrors this. **Scope (this PR):** 1. **`playwright.yml` + `api-testing.yml`** → new report jobs → `ci_test_runs` (`suite=ui` / `suite=api`). 2. **`playwright_regression.yml`** → retry-aware reporting → `ci_regression` (OSS: augments the existing job; ENT: adds the job — was uninstrumented). ## How it works - **Shared `.github/scripts/o2-run-report.sh`** (used by playwright/api) derives the run's `conclusion` from job results, wall-clock from the jobs API, and **sums cost across all attempts**. Regression jobs do the same inline (they also emit shard/build/test fields). - Emits: `run_id`, `run_attempt`, `retries`, `was_retried`, `conclusion`, `suite`, `repo`, `branch`, `author`, `commit_sha`, `pr_number`, `trigger`, `final_duration_sec`, `total_duration_sec`, `retry_wasted_sec`. - **Dedup model:** re-runs append one doc per attempt; dashboards keep the **latest attempt per `run_id`** via `row_number() OVER (PARTITION BY run_id ORDER BY run_attempt DESC)`. Retries become an *attribute*, never duplicate rows; `total_duration_sec` on the kept row carries cumulative compute. - **Safe by construction:** `continue-on-error` + the never-fail poster — can't fail/slow a test run; skips when no tests ran; **no-ops until `O2_REPORTING_*` secrets are set**. ## Review AI review addressed (mktemp payload, `GH_TOKEN` guard, non-negative duration clamp). YAML + jq unit-tested + `actionlint` clean on the added jobs. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>