A machine whose presence says online is heard now; last heard is otherwise the later of last_seen and the presence time (issue 1156)

This commit is contained in:
2026-10-18 21:04:59 +02:00
parent 7be2df627f
commit fb66608a13
4 changed files with 61 additions and 27 deletions
+1 -1
View File
@@ -483,7 +483,7 @@ func (w *watchdogs) gatherMachines(ctx context.Context, inv *inventory.Inventory
// What the watchman says of each machine: its stuck presence key is the silent verdict, and presence.<node>'s time when
// it was last heard (ADR 0433 §3). Unreadable is said, and the heartbeat rule judges as before.
if w.js != nil {
if err := withPresence(ctx, w.js.Conn(), out); err != nil {
if err := withPresence(ctx, w.js.Conn(), out, now); err != nil {
fmt.Printf("what the watchman says of the machines' presence cannot be read: %v\n", err)
} else {
for _, m := range out {