Expand description
The agents of other AgentMux instances, for the Swarm’s sections below this
instance’s own tree (docs/specs/SPEC_SWARM_OTHER_HOSTS_AND_CHANNELS_2026_10_02.md).
Phase 2 adds LAN hosts, from the LAN discovery peer list (mDNS and the UDP
route): one host per hostname, one channel per advertising instance, names
from each peer’s agents list.
Phase 1: other channels on this machine, read from the host-global shared
registry (reactive::registry::list_all_shared), the same source the
/agentmux/discovery endpoint’s host.cross_channel uses. Names only: the
registry carries no status, provider or summary. LAN hosts and cloud installs
are later phases and arrive as more RemoteHosts with their own tier.
Phase 4 adds each agent’s state (working, waiting, idle, …) where its
instance reports one: a LAN peer’s from the agent-names poll the discovery
loop already makes, another channel’s from the same route asked over
loopback (channel_statuses). With it, by the owner’s decision of
2026-10-13, each agent’s summary line where its instance shares one
(backend::agent_line).
Nothing here carries a credential to the frontend: the registry’s auth_key
and local_url are dropped.
Structs§
- Channel
Report - What one channel of this machine said about its agents, by lower-cased name.
- Channel
Status Target - One instance to ask for its agents’ states:
(channel, local_url, auth_key). - Paired
Computer - A computer this one paired with, as far as the Swarm needs it to tell which LAN host it is.
- Peer
Route - A LAN peer’s address and the broadcast key it advertised.
- Remote
Agent - Remote
Channel - Remote
Host - Swarm
Other Instances Result - Response of
swarm.other-instances.
Constants§
- HIDE_
AFTER_ MS - Past this an entry is not shown at all. The registry’s own startup sweep only drops entries older than 4 h, and a crashed channel should not look present for that long.
- STALE_
AFTER_ MS - A registry entry not rewritten for this long is shown as stale. The registry heartbeat rewrites every live agent’s entry every 20 s, so this is three missed beats.
Functions§
- channel_
status_ targets - The instances whose agents
other_channelslists and that are worth asking: one perlocal_url, loopback only (as the cross-channel fleet forwarder requires), never this instance, and not a stale one, whose rows are dimmed and show no state. - channel_
statuses - Asks each target’s
agent-namesroute, concurrently, for its agents’ states and lines. A target that fails, times out or answers badly contributes nothing. - defined_
providers - The definitions’ providers for
entries, read from the host-global definition store. Blocking: it reads one file per agent. - fill_
account_ labels - Name each remote agent’s account when the same account is signed in on this machine: two machines’ sign-ins of one provider account share the stable id, and the label is this machine’s own. An account that is not signed in here keeps its id and gets no label.
- fill_
defined_ providers - Give this machine’s other channels’ agents the provider their definition records, where their instance reported none: an instance from before it reported providers (0.59.30 and older) still shows its agents’ icons (REPORT_SWARM_REMOTE_PROVIDER_ICON_RCA_2026_10_18.md §6.1). A provider the instance reported wins: it describes the live pane. LAN hosts are left as they are: their definitions aren’t on this machine.
- lan_
hosts - LAN hosts from the discovery peer list. A peer at one of this machine’s own addresses is another channel on this host, which the registry already lists (with more detail), so it is left out here. A peer that did not advertise its channel (an older build) is labelled by its port, so two of them on one host stay apart.
- other_
channels - Group the shared registry’s entries into this machine’s other channels.
- paired_
computers - The computers this one paired with to watch their agents.
- snapshot
- The full answer: this machine’s other channels as one host (absent when there are none), then the LAN hosts.
Type Aliases§
- Account
Labels - This machine’s label for each account signed in on it, by the id every
machine agrees on (
identity::stable_account). - Channel
Statuses - Each channel’s report, by channel.
- Defined
Providers - Each agent’s provider id as this machine’s agent definitions record it, by
the
uidits registry entry carries; a known id only.