Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Plan execution states

Generated from crucible/src/plan/machine.rs by crucible plan states; scripts/state-docs.sh --check keeps it current. The executor walks both tables at every decision, so an edge missing here is a path it cannot take. The graph itself, what the tasks are and how they depend on each other, is described in Work graphs; this page is how the executor walks one.

One task

A task is pending until its dependencies settle, runs (retrying transport-class failures up to the configured count), and settles on one of the six statuses the session log reports. Everything that reaches a settled state without an attempt is a blocked task, and the edge names why.

One task's states

The plan

The plan dispatches ready tasks in topological order until every task has settled or a required task fails or a ceiling is reached. After a halt the remaining tasks settle as blocked; epilogue tasks still run after a required task fails so the failure is reported.

The plan's states

The sources are docs/img/plan-task-states.dot and docs/img/plan-states.dot (crucible plan states --format dot).

Why a task is blocked

The note on a blocked task's result is one of these.

NoteMeaning
required task <task> failedA required task failed and the plan short-circuited before this one ran.
budget ceiling reachedThe plan's spend reached its budget.
wall-clock ceiling reachedThe plan's wall-clock limit passed.
dependency did not passA dependency settled without passing and the task's join needs it to.
<the runner's reason>The runner could not stage the task's declared inputs.

How a plan ends

StateTokenMeaning
CompletedfinishedEvery task settled; the plan is valid when every required task passed.
Haltederror or budgetA required task failed (error), or a budget or wall-clock ceiling was reached (budget); the rest drained as blocked.
TruncatederrorA required task cannot run on this substrate; nothing was dispatched.