Skip to main content

stormchaser_model/
lib.rs

1//! Core data models and domain types for the Stormchaser workflow engine.
2//!
3//! This crate provides the foundational types representing workflows, steps,
4//! executions, and other entities that make up the domain model.
5
6/// Authentication and authorization models.
7pub mod auth;
8/// Cron scheduling definitions.
9pub mod cron;
10/// Domain-Specific Language (DSL) abstract syntax tree and types.
11pub mod dsl;
12/// System event and correlation models.
13pub mod event;
14/// Rule-based trigger definitions for events.
15pub mod event_rules;
16/// HCL expression evaluation models.
17pub mod hcl_eval;
18/// Logging configuration and log streaming types.
19pub mod logging;
20/// Outbox pattern models for reliable message publishing.
21pub mod outbox;
22/// Execution runner definitions and status models.
23pub mod runner;
24/// Workflow step execution models and state.
25pub mod step;
26/// Storage backend and artifact registry models.
27pub mod storage;
28/// Test reporting and summary models.
29pub mod test_report;
30/// Core workflow run and state management types.
31pub mod workflow;
32
33pub use auth::{ApiOpaContext, Claims, EngineOpaContext, OpaClient};
34pub use dsl::{ApprovalSpec, WaitEventSpec};
35pub use event::{ApprovalRegistry, EventCorrelation};
36pub use event_rules::{EventRule, WebhookConfig};
37pub use logging::LogBackend;
38pub use outbox::OutboxMessage;
39pub use runner::{Runner, RunnerStatus, StepDefinition};
40pub use step::{StepInstance, StepOutput, StepStatus};
41pub use storage::{BackendType, StorageBackend};
42pub use test_report::{TestCase, TestCaseStatus, TestReport, TestSummary};
43pub use workflow::{AuditLog, RunContext, RunQuotas, RunStatus, WorkflowRun};
44
45/// Engine trait for scheduling and managing workflow runs.
46pub trait WorkflowEngine {
47    /// Schedules a new workflow run by name.
48    fn schedule_run(&self, name: &str) -> anyhow::Result<WorkflowRun>;
49}