fix(#2398): correct stale doc on handle_restart_scoped

argus caught it: the function-level /// comment still described the
old submit-await-submit graceful approach after the code moved to
one atomic GracefulRestart DAG.
This commit is contained in:
atlas 2026-07-14 20:26:59 +02:00 committed by mara
commit 407965b6e1

View file

@ -637,14 +637,14 @@ async fn handle_start(
/// Restart containers hive-wide (`hivectl restart`) — the DAG-based /// Restart containers hive-wide (`hivectl restart`) — the DAG-based
/// sibling of [`handle_stop`]/[`handle_start`], replacing the old /// sibling of [`handle_stop`]/[`handle_start`], replacing the old
/// client-side stop-then-start composition (issue tracker "dagify hivectl /// client-side stop-then-start composition (issue tracker "dagify hivectl
/// commands"). Each targeted agent gets exactly one atomic `Restart` /// commands"). Each targeted agent gets exactly one atomic DAG submitted
/// template DAG in the common (non-graceful) case, so it survives a /// up front: the `Restart` template (mechanical stop + reconcile) in the
/// dropped `hivectl` connection the same way `handle_restart_all` already /// common case, or `GracefulRestart` (signal → drain → mechanical stop →
/// does. `graceful` has no single-DAG template yet, so it falls back to /// reconcile) with `graceful` set — no "submit a DAG, wait for it, submit
/// submitting the graceful-stop DAGs, waiting them out server-side, then /// another" composition on either path, so a dropped `hivectl` connection
/// submitting the start DAGs — still one daemon call end to end, unlike /// never strands an agent, the same way `handle_restart_all` already
/// the old CLI-side compose. Infra containers have no lease/DAG and /// avoids it. Infra containers have no lease/DAG and restart
/// restart synchronously (stop then start). /// synchronously (stop then start).
async fn handle_restart_scoped( async fn handle_restart_scoped(
coord: &Arc<Coordinator>, coord: &Arc<Coordinator>,
scope: &LifecycleScope, scope: &LifecycleScope,