From 8fe6217b5ac046d36187983dbb9d298ba76b5f8c Mon Sep 17 00:00:00 2001 From: archipelago Date: Thu, 30 Jul 2026 23:33:32 -0400 Subject: [PATCH] =?UTF-8?q?fix(02-08):=20cap=20content.browse-peer=20fan-o?= =?UTF-8?q?ut=20=E2=80=94=20root=20cause=20of=20Cloud=20first-visit=20hang?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Instrumented the exact trigger the fresh-mount guard (previous commit) didn't fully eliminate: on a fresh session, loadPeerFiles() fired one content.browse-peer RPC per connected peer with zero concurrency cap and a 30s per-call timeout. Confirmed on archi-dev-box: 13 of 14 concurrent browse-peer calls never settled at all (dead/unreachable peers with no server-side timeout on that path) — that many simultaneously open, indefinitely-pending same-origin requests starved Chromium's connection pool, silently breaking every other same-origin fetch for the rest of the session, including the lazy route chunk any later folder/tab navigation needs. This — not the router or the click handler — was the actual cause of "no folders open on click" after a first Cloud visit. Fix, mirroring PeerFiles.vue's existing PREVIEW_CONCURRENCY pattern for the identical class of problem (content.preview-peer fan-out): - Cap the browse-peer fan-out at 3 concurrent requests (BROWSE_PEER_CONCURRENCY, a queue+worker pool in loadPeerFiles()). - Shorten each call's timeout from 30s to 10s (BROWSE_PEER_TIMEOUT_MS) — bounds how long any one dead peer can hold a connection. - Wire an AbortController (aborted onUnmounted) through rpc-client's signal option for clean teardown. - A timed-out/failed peer already resolved silently through resources.ts's own error-state path (no throw, no toast) — confirmed unchanged; the muted "N peers unreachable" line is the only surface. No visual/behavioral change to the working case (D-01 rule) — peers that answer still render exactly as before, just no longer share the page with a dozen never-ending requests. Full suite green (95 files / 774 tests), type-check and build clean, keepAliveTabs.test.ts structural DOM assertions untouched. Co-Authored-By: Claude Fable 5 --- neode-ui/src/views/Cloud.vue | 52 ++++++++++++++++++++++++++++++++---- 1 file changed, 47 insertions(+), 5 deletions(-) diff --git a/neode-ui/src/views/Cloud.vue b/neode-ui/src/views/Cloud.vue index 5eace497..f62b344e 100644 --- a/neode-ui/src/views/Cloud.vue +++ b/neode-ui/src/views/Cloud.vue @@ -402,7 +402,7 @@