pub struct WorkflowDefinition {
pub id: String,
pub name: String,
pub version: Version,
pub description: String,
pub stages: Vec<WorkflowStage>,
pub transitions: HashMap<(StageId, WorkflowEvent), StageId>,
pub timeouts: HashMap<StageId, Duration>,
pub error_handlers: HashMap<StageId, ErrorHandler>,
pub initial_stage: StageId,
pub final_stages: Vec<StageId>,
pub global_timeout: Option<Duration>,
pub metadata: HashMap<String, String>,
}Expand description
Complete workflow definition
Fields§
§id: StringUnique identifier for this workflow type
name: StringHuman-readable name
version: VersionVersion of this workflow
description: StringDescription of the workflow
stages: Vec<WorkflowStage>Workflow stages
transitions: HashMap<(StageId, WorkflowEvent), StageId>State transition rules
timeouts: HashMap<StageId, Duration>Timeout for each stage
error_handlers: HashMap<StageId, ErrorHandler>Error handlers for each stage
initial_stage: StageIdInitial stage
final_stages: Vec<StageId>Final stages (success endpoints)
global_timeout: Option<Duration>Global timeout for entire workflow
metadata: HashMap<String, String>Metadata
Trait Implementations§
Source§impl Clone for WorkflowDefinition
impl Clone for WorkflowDefinition
Source§fn clone(&self) -> WorkflowDefinition
fn clone(&self) -> WorkflowDefinition
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for WorkflowDefinition
impl Debug for WorkflowDefinition
Source§impl<'de> Deserialize<'de> for WorkflowDefinition
impl<'de> Deserialize<'de> for WorkflowDefinition
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for WorkflowDefinition
impl !RefUnwindSafe for WorkflowDefinition
impl Send for WorkflowDefinition
impl Sync for WorkflowDefinition
impl Unpin for WorkflowDefinition
impl !UnwindSafe for WorkflowDefinition
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more