refactor(#2897): carry the meta-update inputs on the MetaLock node

Second of the `Dag` field removals, and the same shape as the first:
`DagSpec`/`NodeKind::Dag` carried an `inputs: Vec<String>` that exactly
one node ever read. Both reads live inside `run_meta_lock` — the
`meta::lock_update` call and the `meta_update_cascade_agents` fan-out —
so the list now rides `NodeKind::MetaLock` itself.

The executor stops touching `Claim` for this node entirely: its dispatch
arm already destructured `MetaLock { sweep, fanout }`, so `inputs` joins
them and the `claim` parameter, which had no other use, is gone.

Falls out of that:
- `Claim::inputs` and `DagMeta::inputs` delete.
- `dag_view`'s DAG-level projection onto the `MetaLock` node reads the
  payload instead. The wire `NodeView::inputs` is unchanged: still
  populated on the `meta_lock` node alone.
- the boot sweep names no inputs (it bumps `hyperhive` alone via
  `lock_update_hyperhive`), which the construction site now says out loud
  rather than leaving implicit in an empty DAG-level field.

Checked with clippy (`--all-targets -D warnings`), `cargo test -p
hive-c0re` (320 passed) and `nix fmt`. No option surface is touched, so
no nix-eval gate.
This commit is contained in:
atlas 2026-08-01 13:23:19 +02:00
commit af2b1ce0e2
7 changed files with 22 additions and 31 deletions

View file

@ -70,7 +70,6 @@ pub struct Claim {
/// The agent this node targets (its own, not a DAG-level field). Empty for
/// the agentless [`NodeKind::MetaLock`] + [`NodeKind::Dag`] container nodes.
pub agent: String,
pub inputs: Vec<String>,
/// Transient pill kind for the lease window (from the spec). Whether the
/// pill is currently shown is derived from live lease ownership
/// ([`JobQueue::held_transients`]), not a per-claim edge.
@ -93,7 +92,6 @@ struct DagMeta {
source: Source,
reason: String,
transient: Option<TransientKind>,
inputs: Vec<String>,
created_at: i64,
}
@ -218,7 +216,6 @@ impl JobQueue {
source: spec.source,
reason: spec.reason,
transient: spec.transient,
inputs: spec.inputs,
created_at: now_unix(),
},
Vec::new(),
@ -304,7 +301,6 @@ impl JobQueue {
node_id: id,
kind,
agent,
inputs: meta.inputs,
transient: meta.transient,
});
// `started_at` is stamped on the graph `Node` by the scheduler's
@ -481,7 +477,6 @@ impl QueueInner {
source,
reason,
transient,
inputs,
created_at,
} = &self.sched.graph().node(container)?.payload
else {
@ -491,7 +486,6 @@ impl QueueInner {
source: *source,
reason: reason.clone(),
transient: *transient,
inputs: inputs.clone(),
created_at: *created_at,
})
}
@ -549,10 +543,9 @@ impl QueueInner {
NodeKind::DeployWindow { approval_id, .. } => Some(*approval_id),
_ => None,
};
let inputs = if matches!(node.payload, NodeKind::MetaLock { .. }) {
meta.inputs.clone()
} else {
Vec::new()
let inputs = match &node.payload {
NodeKind::MetaLock { inputs, .. } => inputs.clone(),
_ => Vec::new(),
};
let build_log_id = self.node_rt.get(&id).and_then(|r| r.build_log_id);
// `node.parent` is the structural jobq parent. Top-level nodes