Skip to content

ci(playwright): capture full server log + OpenSearch stats on E2E failure#30249

Merged
pmbrull merged 1 commit into
mainfrom
pmbrull/ci-full-server-log-on-failure
Jul 21, 2026
Merged

ci(playwright): capture full server log + OpenSearch stats on E2E failure#30249
pmbrull merged 1 commit into
mainfrom
pmbrull/ci-full-server-log-on-failure

Conversation

@pmbrull

@pmbrull pmbrull commented Jul 20, 2026

Copy link
Copy Markdown
Member

Describe your changes:

Follow-up to the failure-diagnostics step added in #30120.

That step dumps docker compose logs --tail 5000 on failure. On a ~2h shard the OpenMetadata server is chatty enough that 5000 lines only covers the last ~1 minute (the job-teardown window). I confirmed this on a real chart-test failure: the captured docker-compose.log server section spanned only 19:09–19:10 (teardown), while the failing test ran ~20 min earlier — so the index writes and search queries needed to debug it were truncated away. (OpenSearch's own log, being far less chatty, did span the whole run and showed it healthy — no rejections/OOM/GC — which is why the server log is the missing piece.)

This adds, alongside the existing tailed all-services log:

  • the full (untailed) openmetadata-server log, and
  • OpenSearch _cat/thread_pool (cumulative rejected/completed counters for write/refresh/search — these survive the tail window and reveal any rejections over the whole run) and _cat/indices (per-index docs.count + refresh stats).

This makes the recurring chart custom-property E2E flakiness — where the server log is exactly what's missing — diagnosable on the next failure.

Type of change:

  • Chore / CI

Tests:

CI-only change (adds artifacts on failure()); no product code touched.

Checklist:

  • I have read the CONTRIBUTING document.

🤖 Generated with Claude Code

Greptile Summary

This PR expands failure diagnostics for PostgreSQL Playwright runs. The main changes are:

  • Captures the complete openmetadata-server log.
  • Records OpenSearch thread-pool counters.
  • Records per-index OpenSearch statistics.

Confidence Score: 5/5

The workflow looks mergeable after hardening the full-log capture against runner disk exhaustion.

  • Service names, OpenSearch connectivity, step ordering, and artifact paths match the existing workflow configuration.
  • The full server log has no size bound and can consume the disk needed by later diagnostics and artifact upload.

.github/workflows/playwright-postgresql-e2e.yml

Important Files Changed

Filename Overview
.github/workflows/playwright-postgresql-e2e.yml Adds full server logs and OpenSearch statistics to failure artifacts, with a possible runner-disk risk from the unbounded log copy.

Reviews (1): Last reviewed commit: "ci(playwright): capture full server log ..." | Re-trigger Greptile

Greptile also left 1 inline comment on this PR.

Context used (3)

  • Context used - CLAUDE.md (source)
  • Context used - openmetadata-ui-core-components/CLAUDE.md (source)
  • Context used - AGENTS.md (source)

…lure

The failure-diagnostics step (#30120) dumps `docker compose logs --tail 5000`.
On a ~2h shard the OpenMetadata server is chatty enough that 5000 lines only
covers the last ~1 minute (job teardown), so the failing test's actual window —
including the index writes and search queries we need to debug flaky
"entity not found in search" failures — is truncated away.

Add, alongside the existing tailed all-services log:
- the full (untailed) openmetadata-server log, and
- OpenSearch `_cat/thread_pool` (cumulative write/refresh/search rejected +
  completed counters, which survive the tail window) and `_cat/indices`
  (per-index docs.count + refresh stats).

This makes the chart custom-property flakiness — where the server log is exactly
what's missing — diagnosable on the next failure.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings July 20, 2026 19:26

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions

Copy link
Copy Markdown
Contributor

❌ PR checklist incomplete

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

  • No GitHub issue is linked. Link an issue in the Development section of the PR (or add Fixes #12345 to the description). For a same-org cross-repo issue, add Fixes open-metadata/<repo>#123 to the description.

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 added Ingestion safe to test Add this label to run secure Github workflows on PRs labels Jul 20, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🔴 Playwright Results — 16 pipeline/setup failure(s)

✅ 0 passed · ❌ 0 failed · 🟡 0 flaky · ⏭️ 0 skipped

Pipeline and setup failures

  • The build job finished with status failure.
  • The Playwright shard matrix was unexpectedly skipped.
  • Shard 1 did not upload a usable Playwright results artifact.
  • Shard 2 did not upload a usable Playwright results artifact.
  • Shard 3 did not upload a usable Playwright results artifact.
  • Shard 4 did not upload a usable Playwright results artifact.
  • Shard 5 did not upload a usable Playwright results artifact.
  • Shard 6 did not upload a usable Playwright results artifact.
  • Shard 7 did not upload a usable Playwright results artifact.
  • Shard 1 did not upload its execution status.
  • Shard 2 did not upload its execution status.
  • Shard 3 did not upload its execution status.
  • Shard 4 did not upload its execution status.
  • Shard 5 did not upload its execution status.
  • Shard 6 did not upload its execution status.
  • Shard 7 did not upload its execution status.
Shard Passed Failed Flaky Skipped
⛔ Shard 1
⛔ Shard 2
⛔ Shard 3
⛔ Shard 4
⛔ Shard 5
⛔ Shard 6
⛔ Shard 7

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

@gitar-bot

gitar-bot Bot commented Jul 20, 2026

Copy link
Copy Markdown
Code Review ✅ Approved

Increases server log visibility for E2E failures by capturing full logs and OpenSearch thread pool/index statistics. No issues found.

Options

Display: compact → Showing less information.

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

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

Comment on lines +490 to +492
docker compose -f docker/development/docker-compose-postgres.yml \
logs --no-color --no-log-prefix openmetadata-server \
> "$DIAGNOSTICS_DIR/openmetadata-server-full.log" 2>&1 || true

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 Unbounded Log Can Exhaust Disk

On a noisy multi-hour shard, this command copies the server's entire Docker log into a second unbounded file on the runner. If that consumes the remaining disk, the log can be truncated and the later OpenSearch files or artifact upload can fail, leaving the failed run without the diagnostics this step is meant to preserve; stream compression or another bounded capture strategy would avoid duplicating the full log on disk.

@pmbrull
pmbrull merged commit 24683a7 into main Jul 21, 2026
49 of 53 checks passed
@pmbrull
pmbrull deleted the pmbrull/ci-full-server-log-on-failure branch July 21, 2026 04:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ingestion safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants