test(sfu): add SFU capacity load test and client instrumentation
HA
2mo ago+990+990+012345678901234567890123456789-7-7-0123456789
Summary by cubic
Adds an SFU capacity load test that drives a real media session and measures join and first-frame latency as viewers are added in batches. Results show latency and failures climbing past ~65 concurrent viewers.
Test setup and instrumentation
- The Puppeteer script logs in, starts a broadcaster, then adds viewers in batches of 5 up to 100, writing P50/P99 latencies and failure counts to
load-test/sfu-capacity-results.csv. - Broadcaster and viewer pages expose
__csRoomId,__csLiveAt,__csJoinedAt, and__csFirstFrameAtonwindowso the test can time room creation, join, and first frame. /broadcaster,/viewer, and/dashboardare no longer wrapped inProtectedRoute, so they load without authentication in every environment.- Broadcaster connects its socket on mount and disconnects on unmount; ViewerPage switched from
getSockettoconnectSocket. - Backend now logs the socket disconnect reason and details at error level instead of info level.