lazy load fat modules, cut WS sizes + start dropping notifications at a certain point

This commit is contained in:
KingKDot
2026-04-17 13:49:06 -05:00
parent 77ddc397a0
commit 4a062e3a19
8 changed files with 61 additions and 23 deletions
@@ -168,7 +168,7 @@ function buildViewerFrameBuffer(bytes: Uint8Array, header?: any): Uint8Array {
return buf;
}
const VIEWER_BACKPRESSURE_BYTES = 4 * 1024 * 1024; // 4 MB
const VIEWER_BACKPRESSURE_BYTES = 2 * 1024 * 1024; // 2 MB
function broadcastFrameToViewers(
sessions: Iterable<{ viewer: ServerWebSocket<SocketData> }>,