Web performance: table help, Setup card, defaults test, enforce reportRetentionDays #12

Merged
KofTwentyTwo merged 2 commits from feature/tables-populated-defaults into develop 2026-10-14 22:19:51 +00:00
KofTwentyTwo commented 2026-10-14 22:06:57 +00:00 (Migrated from github.com)

Audit

  • All 9 tables are read/written by runtime code. budget is seeded by existing changeset 10 (13 reference budgets; unchanged, no new changeset). target is synced from the sitemap; the other seven are runtime logs and start empty.
  • CONTENT_TABLE scope: already handled in WebPerfEvaluationService.matches and covered by WebPerfRegressionTest.matchesBudgetScopesComparatorsAndSeverity (all five scopes).
  • Half-wired, fixed: reportRetentionDays was documented and validated but nothing read it. Now enforced when a report is stored; test WebPerfP1Test.testReportRetention (0 keeps, 30 deletes a 40-day-old report).

Changes

  • help/web-performance.yaml + WebPerfHelp (STAND-IN core#1198).
  • Setup card (WebPerfSetupStatus, first home widget): tested pages, lab runner, budgets (defaults vs own), Google field data; uses runtime.labRunner()/cruxClient()/url source resolution. Test testSetupCard.
  • WebPerfDefaultsChangelogTest: shipped changelog through real Liquibase on H2 (PostgreSQL mode; liquibase-core as test dep): 13 seeds, second update runs nothing, seed re-run inserts nothing and keeps an edit.
  • WebPerfTablesGuardrailTest. Docs: README, UPGRADE, CHANGELOG.

Not done

  • Seeded budgets with source RUM (7 of the 13) are never evaluated: no real-user source consumes RumSource. The budget help says so. The CrUX evaluator only reads source CRUX budgets, and none are seeded. Seeding CRUX budgets would change behavior on deploy (new regressions), so it needs an owner decision.
  • Config with no consumer in main code: RUM_VIEW/rumSource, TRIGGERS_ESB, publishSettleSeconds, deploySettleSeconds, concurrency (not tables; left as is).

./mvnw verify green.

🤖 Generated with Claude Code

## Audit - All 9 tables are read/written by runtime code. `budget` is seeded by existing changeset 10 (13 reference budgets; unchanged, no new changeset). `target` is synced from the sitemap; the other seven are runtime logs and start empty. - `CONTENT_TABLE` scope: already handled in `WebPerfEvaluationService.matches` and covered by `WebPerfRegressionTest.matchesBudgetScopesComparatorsAndSeverity` (all five scopes). - Half-wired, fixed: `reportRetentionDays` was documented and validated but nothing read it. Now enforced when a report is stored; test `WebPerfP1Test.testReportRetention` (0 keeps, 30 deletes a 40-day-old report). ## Changes - `help/web-performance.yaml` + `WebPerfHelp` (STAND-IN core#1198). - Setup card (`WebPerfSetupStatus`, first home widget): tested pages, lab runner, budgets (defaults vs own), Google field data; uses `runtime.labRunner()`/`cruxClient()`/url source resolution. Test `testSetupCard`. - `WebPerfDefaultsChangelogTest`: shipped changelog through real Liquibase on H2 (PostgreSQL mode; liquibase-core as test dep): 13 seeds, second update runs nothing, seed re-run inserts nothing and keeps an edit. - `WebPerfTablesGuardrailTest`. Docs: README, UPGRADE, CHANGELOG. ## Not done - Seeded budgets with source RUM (7 of the 13) are never evaluated: no real-user source consumes `RumSource`. The budget help says so. The CrUX evaluator only reads source CRUX budgets, and none are seeded. Seeding CRUX budgets would change behavior on deploy (new regressions), so it needs an owner decision. - Config with no consumer in main code: `RUM_VIEW`/`rumSource`, `TRIGGERS_ESB`, `publishSettleSeconds`, `deploySettleSeconds`, `concurrency` (not tables; left as is). `./mvnw verify` green. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.