pub enum Command {
Show 20 variants
ApplyChange {
changes: Vec<EntityChange>,
reason: String,
},
RevertChange {
operation: OperationId,
changes: Vec<EntityChange>,
reason: String,
},
RatifyContract {
work: WorkItemId,
},
Reject {
work: WorkItemId,
reason: String,
},
Claim {
work: WorkItemId,
},
Release {
work: WorkItemId,
reason: String,
},
Handoff {
work: WorkItemId,
from: ActorId,
to: ActorId,
reason: String,
},
Start {
work: WorkItemId,
occurred_at: Option<DateTime<Utc>>,
},
Block {
work: WorkItemId,
reason: String,
},
Unblock {
work: WorkItemId,
},
ReportProgress {
work: WorkItemId,
percent: u8,
note: Option<String>,
},
Submit {
work: WorkItemId,
note: Option<String>,
occurred_at: Option<DateTime<Utc>>,
},
Verify {
work: WorkItemId,
note: Option<String>,
occurred_at: Option<DateTime<Utc>>,
},
AttachArtifact {
work: WorkItemId,
artifact: Artifact,
},
WaiveDependency {
dependency: DependencyId,
reason: String,
},
RestoreDependency {
dependency: DependencyId,
reason: String,
},
RevalidateBasis {
work: WorkItemId,
dependency: DependencyId,
attempt: u32,
reason: String,
},
Decide {
decision: DecisionId,
outcome: String,
},
LinkExternal(ExternalLinkRequest),
UnlinkExternal {
work: WorkItemId,
reference: ExternalReferenceId,
},
}Expand description
A semantic state change; adapters must use the engine to apply it.
Variants§
ApplyChange
Apply a reviewed plan proposal without bypassing execution history; built from a full
proposal by crate::plan_change.
Fields
changes: Vec<EntityChange>The canonical entity-level difference from the operation’s base revision, in the
order crate::propose_change reports it; every before must match that state.
RevertChange
Undo a recorded plan change by applying its reviewed inverse, as a new operation that names the one it reverts; the history is never rewritten.
Fields
operation: OperationIdThe recorded plan change being undone.
changes: Vec<EntityChange>The inverse exactly as crate::propose_revert reports it for the current plan.
RatifyContract
Approve a proposed execution contract as a human or service.
Fields
work: WorkItemIdProposed task with a complete objective and acceptance criteria.
Reject
Return submitted work to its owner with an independent review.
Fields
work: WorkItemIdSubmitted task to return for rework.
Claim
Reserve a ready task for the calling actor; a claim is not a start.
Fields
work: WorkItemIdTask to reserve.
Release
Give up the caller’s own unstarted claim, returning the task to Planned without an owner.
Fields
work: WorkItemIdClaimed task owned by the caller.
Handoff
Transfer claimed, started or blocked work to another owner, authorized by a human or service; every recorded execution fact stays with the work.
Fields
work: WorkItemIdTask changing owners.
Start
Begin executing a claimed task, recording its start event.
Fields
work: WorkItemIdClaimed task owned by the caller.
Block
Suspend a task while preserving any existing owner.
Unblock
Resume blocked work, preserving its owner.
Fields
work: WorkItemIdTask to resume.
ReportProgress
Report task execution progress without accepting its result.
Fields
work: WorkItemIdOwned task receiving the report.
Submit
Request independent verification of owned work.
Fields
work: WorkItemIdTask whose result is submitted.
Verify
Accept a submitted result as a different actor.
Fields
work: WorkItemIdSubmitted task to verify.
AttachArtifact
Attach new evidence without replacing an existing artifact.
Fields
work: WorkItemIdWork receiving evidence.
WaiveDependency
Stop enforcing a soft constraint as a human or service, recording who, when and why.
Fields
dependency: DependencyIdSoft constraint to set aside.
RestoreDependency
Enforce a waived soft constraint again; the operation records who, when and why.
Fields
dependency: DependencyIdWaived constraint to enforce again.
RevalidateBasis
Record, as an independent human or service, that started work built on a rejected predecessor attempt remains valid on the predecessor’s current attempt.
Fields
work: WorkItemIdSuccessor whose basis on the edge was invalidated.
dependency: DependencyIdProvisional edge carrying the invalidated basis.
Decide
Resolve an open gate.
LinkExternal(ExternalLinkRequest)
Link work to an external tracker object without granting it local authority.
UnlinkExternal
Remove one work item’s link to an external object; the last link removes the record.
Fields
work: WorkItemIdWork whose link is removed.
reference: ExternalReferenceIdLinked external reference.