Watch
0
0
Fork
You've already forked hyperhive
0

swarm-controller: put a failed jobq node's error in the log message

This commit is contained in:
damocles 2026-11-09 15:51:32 +01:00 • committed by mara
commit 15964a06f8
2 changed files with 4 additions and 4 deletions

View file

@ -23,8 +23,8 @@ The swarm's control plane. The swarm UI and `swarmctl` are its clients.
one hive whose declaration places it.
- **Job graph** — a `hive-jobq` scheduler, served at `GET /api/jobq/graph`.
Every provisioning step below runs as a node in it. A node that fails logs
one `warn` line, `swarm jobq: node failed`, with its `node` id, `kind` and
`error`.
one `warn` line, `swarm jobq: node failed: <error>`, with its `node` id and
`kind`.
- **Agent creation** — `POST /api/agents` queues the SSO identity (through
`swarm-authelia-bridge`), forge user, config repo, store identity, forge
token and matrix account, declares the agent `paused`, then sends its hive

View file

@ -344,7 +344,7 @@ pub(crate) async fn run_swarm_node(
let node_kind = hive_jobq_wire::WireNode::label(&kind);
let (builder, outcome) = run_node_work(kind, builder, deps).await;
if let hive_jobq::scheduler::Outcome::Failed(error) = &outcome {
tracing::warn!(node = id.get(), kind = %node_kind, %error, "swarm jobq: node failed");
tracing::warn!(node = id.get(), kind = %node_kind, "swarm jobq: node failed: {error}");
}
(builder, outcome)
}
@ -4797,7 +4797,7 @@ mod mint_identity_tests {
assert_eq!(field("kind"), "set_agent_wanted");
assert_eq!(field("node"), ids[0].get().to_string());
assert!(
field("error").contains("no swarm queue is configured"),
field("message").contains("no swarm queue is configured"),
"{fields:?}"
);
}