Retry and backoff
ArcFlow retries failed steps and workflows using configurable policies at workflow level (exec_config.retry) and step level (retry_policy on steps or workflow). Backoff kinds include fixed, linear, and exponential with optional jitter. Traces emit RetryAttempted and RetryExhausted for observability.
Reliability context: Execution model. Complements Step fallbacks (alternate agent after failure) and Timeouts (hard ceilings).
Workflow-level retry (exec_config)
Parsed in server/arcflow-server/src/exec_config.rs; same shape for SDK runs.
Backoff kinds
| kind | Behavior |
|---|---|
fixed | Constant delay between attempts |
linear | Delay increases linearly with attempt number |
exponential | Delay multiplied by multiplier each attempt, capped at max_ms |
Fixed example
Linear example
Exponential example (recommended for provider flakiness)
jitter_ms spreads retries to avoid thundering herds against rate-limited providers.
Step-level retry_policy
Workflow definition may set per-step overrides:
Step policy applies to that step; workflow policy applies as default where step policy is absent.
Trace events
RetryAttempted
RetryExhausted
After exhaustion, the step fails unless Step fallbacks routes to a fallback step (StepFallbackActivated).
Provider rate limits
ProviderRateLimited traces may include retry_after_seconds. Combine retry policy with provider guidance; respect 429 semantics from Provider configuration.
Terminal mapping: RateLimited error code (HTTP 429) when retries do not recover.
Test mode without live LLM
Expect two RetryAttempted events then StepCompleted. See Validation and testing.
External bindings
HTTP callbacks use separate recovery on bindings:
Traces: ExternalRecoveryTriggered. Distinct from step retry but same backoff concepts.
Run status during retry
ExecutionStatus may show Retrying between attempts, then return to Running. Poll GET /v1/runs/{id} on server integrations.