Skip to main content

Module seen_agents

Module seen_agents 

Source
Expand description

The agents a LAN peer has listed, kept after the peer goes quiet.

A peer that stops answering is dropped from LanDiscoveryController::get_instances, and its agents with it, so a message to one of them looks like a message to a name nobody knows. This remembers the name and the host that listed it, so server::reactive::peer_hold can tell “an agent of a machine that is down” from “a name that does not exist”. Kept in lan-seen-agents.json beside the databases, written only when a name appears or moves host (or its record is a day old), so a poll every few seconds costs no writes.

Structs§

SeenAgent
Where a name was last listed.

Functions§

lookup
Where name was last listed by a LAN peer, if one ever listed it (and not over 30 days ago).
remember
Note that hostname listed names at now_secs.