Repository navigation
test(control-ui): add a Team-scale cold-load benchmark - #170033
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesAdds a shared Team-scale Control UI fixture, a production-bundle cold-load benchmark, and release-tier browser coverage. Example: Measure a dashboard reload with 300 sessions, 30 off-page pins, 120 people, and 12 inline widgets.
Review scores
ProductKind: Test only · Worth it: Yes Merge readiness✅ Ready for maintainer review Keep open: this PR provides useful, maintainer-directed performance tooling, and inspection found no actionable introduced defect. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe developer benchmark feeds synthetic Gateway responses and events into the production Control UI in Chromium, then exports traces, profiles, screenshots, and measurement summaries. flowchart LR
A[Team scale fixture] --> B[Mock Gateway and scheduled frames]
B --> C[Production Control UI in Chromium]
D[Loopback sandbox host] --> C
C --> E[Browser probes and Chrome profiling]
E --> F[Trace summaries and artifacts]
Technical reviewBest possible solution: Retain the reusable benchmark and release-tier composition, with measurements explicitly limited to the synthetic renderer workload. Do we have a high-confidence way to reproduce the issue? This is measurement infrastructure rather than a bug fix; supplied benchmark runs exercise the intended production-browser workload, and no target code was executed during review. Is this the best way to solve the issue? The shared fixture and existing production-build, mock-Gateway, sandbox, and CI owners provide a coherent measurement path without duplicating application behavior. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 529b4d75b703. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceTests +884, Docs +87, Other +698. Total +1669 across 10 files. Added test files: 4. View PR surface stats
Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (7 earlier review cycles)
Reviewed October 12, 2026, 4:58 PM ET / 20:58 UTC (Revision 8). |
79c8a05 to
5cf2044
Compare
5cf2044 to
e2f7dda
Compare
Add a reusable synthetic workload and production-bundle renderer measurements for dashboard deep-link reloads. Preserve raw traces, mapped CPU samples, RPC accounting, and filmstrip transitions for campaign comparisons.
e2f7dda to
c337f75
Compare
Related: #142341
What Problem This Solves
The small Control UI cold-load fixture misses the update volume of a signed-in dashboard deep-link reload at Team scale.
User Impact
This adds a reusable synthetic benchmark and browser fixture for performance work; it does not change runtime UI behavior. It never connects to a real account or Gateway.
Why This Change Was Made
The recorded campaign census had roughly 1,500 Lit updates and 93 RPCs, while the earlier small synthetic fixture produced roughly 35 renders. This fixture includes 300 sessions, 30 off-page pins, 34 owners, 120 people, six agents and UI plugins, 240 transcript messages, 12 inline widgets, and separately delivered catalog/presence frames. The runner builds production assets and records Chrome traces, source-mapped CPU profiles, Lit updates, RPC bytes, and automated filmstrip transitions.
The browser composition is registered in the existing
RELEASE_ONLY_UI_TEST_FILEStier. Automatic CI omits it when UI or fixture dependencies select it; the existing exception still runs directly edited test files. Full manual/release validation and an explicitpnpm test ui/src/e2e/team-scale-cold-load.e2e.test.ts --maxWorkers=1invocation retain it. The reusable fixture stays in the normal UI TypeScript graph.The initial three-run Sessions baseline at
488c0a3850fcreproduced 1,091–1,104 Lit updates and 85–86 RPCs. Median renderer busy time was 3,263 ms. The committed benchmark guide records that initial baseline; the historical measurements below use fixture heade2f7ddae04da, based on main823ba031f587.Current baseline and rejected CPU experiment
Blacksmith Testbox
tbx_01m4rv6paf075hqwcrcdcxh4g9, identical production runner, 35 ms reply latency, 4 ms frame spacing, five baseline reloads and five candidate reloads:The candidate moves shared scroll-state reads into ResizeObserver delivery and removes redundant sidebar invalidations. It is not included in this PR and will not be published on this evidence. Although an earlier same-box comparison showed an 8.1% busy-time improvement, this final-head comparison did not reproduce it. Three restored-baseline controls on the same current box returned to 2,760 ms median busy time / 328 ms forced-layout time. The candidate removes the scrollHeight sample but moves expensive geometry work to other readers; it does not establish a repeatable reload improvement. This is a negative benchmark result, not a performance-fix claim.
The current baseline's five largest source-attributed sampled self-time entries, excluding browser program/GC buckets:
scroll-state-observer.ts:19,scrollHeight@solidjs/web/dist/web.js:431lit-html.js:6lit-html.js:6widget-theme.ts:51,getPropertyValueWith the candidate, the leading geometry call site becomes the panel-slot width read in
chat-sidebar-region.runtime.tsx:241(115 ms). Source-attributed CPU samples and browser timings vary; compare repeated captures on the same hardware. Automated filmstrip groups are not equivalent to the campaign's manually labeled visual states.Online reload currently returns to Sessions when live data settles before the cached sidebar snapshot resolves. The Online run deliberately fails rather than mislabeling a Sessions measurement. The browser fixture opens Online explicitly and verifies all 120 people.
Evidence
The Team-scale browser test previously passed in a standalone invocation in 17.73 s wall time, including the production build (4.95 s test time), on Blacksmith
tbx_01m4rfdj3v3whn0m1br52ah0wb. A later shared-build run of that same case took 3.617 s; its selected CI job took 83 s. These are measured invocation, case, and job times respectively, not interchangeable timings.The tier change extends the existing CI planner assertions for default omission, direct-test-edit inclusion, and full validation selection. Formatting and diff checks pass. The pushed head is
c337f7552b4132b3285453ab3bef8c3049f1cc8c, rebased onto maina7c6c126faed. CI on this exact head passed, including normal compilation/type-checking of the fixture and the selected browser tests. On this head, the Team-scale test file took 3.356 s (its single case: 3.199 s); the selected UI E2E job took 63 s. Validation uses normal CI selection; there are no application-runtime changes requiring another full UI run.Independent review found no actionable P0–P2 findings in the tier change.
The required production-LOC command reports +1,328 / −0 lines across six tooling/fixture files. Runtime application changes: zero lines. This growth implements the explicitly requested reusable fixture and measurement contract. No schema, configuration option, or dependency changes.
Limitations: mocked Gateway; tiny synthetic plugin modules; service workers blocked; no HTTP authentication/proxy or server CPU measurement. CPU/profile instrumentation adds overhead, so compare identical runner settings on the same hardware.