You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a remote host is in error or backoff, the only way to reconnect today is to disable and re-enable it in Settings → Remote hosts. The sidebar refresh button (#search-refresh-btn, public/app.js:713) only reindexes local sessions for search; it never touches the remote side.
What exists
remoteIndexer.refreshHostNow(alias) (remote-index.js:237) exists since (remote): push liveness over a persistent watch channel #241 but honours the backoff: if (now() < state.nextAttemptAt) return { skipped: true }. A user-initiated refresh during backoff is silently skipped.
remoteIndexer.refreshNow() is exposed as IPC remote-hosts-refresh (main.js:1517, preload.js:41remoteHostsRefresh) — no renderer caller.
The watch channel (remote-watch.js) is started by syncRemoteWatchers(); a host that ended with the SWITCHBOARD-NO-INOTIFYWAIT marker or that failed is not retried until the next sync (toggle in settings, or restart).
Fix
A manual refresh means "I know the host is back, reconnect now", so it must ignore the backoff and re-arm everything for that host:
refreshHostNow(alias, { force: true }): reset the host's backoff state (failures, nextAttemptAt), then refresh even if nextAttemptAt is in the future. The automatic caller (onRemoteWatchEvent, main.js:486) keeps the non-forced behaviour.
Restart the watch channel for that alias (remoteWatcher.stop(alias) then start) as part of the same action, so a channel killed by a network blip comes back without a settings round-trip.
Renderer: the sidebar refresh button also triggers a forced refresh of every enabled remote host; a per-group refresh action on a remote project header (next to the host dot, remoteHostState(project)) triggers it for that alias only. The host dot switches to its "connecting" state immediately, not after the ssh returns.
Feedback: on failure, the host dot's tooltip shows the fresh error and the next automatic attempt time.
Not in scope
Changing the backoff curve or the default refresh interval.
Acceptance
Host in backoff (simulate with a failing transport): manual refresh runs the ssh inventory immediately and clears the backoff on success; the automatic path still respects it — one test each on the real remote-index.js with an injected clock, and a mutation dropping the force branch makes the manual one red.
After a watch channel exit, manual refresh restarts it (spawn counted in the fake transport).
No behaviour change when no remote host is enabled.
Symptom
When a remote host is in error or backoff, the only way to reconnect today is to disable and re-enable it in Settings → Remote hosts. The sidebar refresh button (
#search-refresh-btn,public/app.js:713) only reindexes local sessions for search; it never touches the remote side.What exists
remoteIndexer.refreshHostNow(alias)(remote-index.js:237) exists since (remote): push liveness over a persistent watch channel #241 but honours the backoff:if (now() < state.nextAttemptAt) return { skipped: true }. A user-initiated refresh during backoff is silently skipped.remoteIndexer.refreshNow()is exposed as IPCremote-hosts-refresh(main.js:1517,preload.js:41remoteHostsRefresh) — no renderer caller.remote-watch.js) is started bysyncRemoteWatchers(); a host that ended with theSWITCHBOARD-NO-INOTIFYWAITmarker or that failed is not retried until the next sync (toggle in settings, or restart).Fix
A manual refresh means "I know the host is back, reconnect now", so it must ignore the backoff and re-arm everything for that host:
refreshHostNow(alias, { force: true }): reset the host's backoff state (failures,nextAttemptAt), then refresh even ifnextAttemptAtis in the future. The automatic caller (onRemoteWatchEvent,main.js:486) keeps the non-forced behaviour.remoteWatcher.stop(alias)thenstart) as part of the same action, so a channel killed by a network blip comes back without a settings round-trip.remoteHostState(project)) triggers it for that alias only. The host dot switches to its "connecting" state immediately, not after the ssh returns.Not in scope
Changing the backoff curve or the default refresh interval.
Acceptance
remote-index.jswith an injected clock, and a mutation dropping theforcebranch makes the manual one red.