Overview
Effects represent interactions with external systems.
They are the only way Lexum interacts with the outside world.
Examples
- API calls
- database writes
- infrastructure changes
Structure
Lexum
effect send_email {
payload { message: string }
}
Execution Boundary
Effects:
-
are isolated from core logic
-
may introduce nondeterminism
Determinism Strategy
Lexum ensures:
-
effect invocation is deterministic
-
effect result handling must be controlled
Idempotency
Effects should be:
-
idempotent
-
retry-safe
Example
lexum
transition notify {
step {
emit send_email("Done")
}
}