1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
//! Execution state management for the AWS Durable Execution SDK.
//!
//! This module provides the core state management types for durable executions,
//! including checkpoint tracking, replay logic, and operation state management.
//!
//! ## Module Structure
//!
//! - `checkpoint_result` - Result types for checkpoint queries
//! - `replay_status` - Replay state tracking
//! - `batcher` - Checkpoint batching for efficient API calls
//! - `execution_state` - Main execution state management
//!
//! ## Checkpoint Token Management
//!
//! The SDK uses checkpoint tokens to ensure exactly-once checkpoint semantics:
//!
//! 1. **Initial Token**: The first checkpoint uses the `CheckpointToken` from the
//! `DurableExecutionInvocationInput` provided by Lambda.
//!
//! 2. **Token Updates**: Each successful checkpoint returns a new token that MUST
//! be used for the next checkpoint. The SDK automatically updates the token
//! after each successful checkpoint.
//!
//! 3. **Token Consumption**: Once a token is used for a checkpoint, it is consumed
//! and cannot be reused. Attempting to reuse a consumed token results in an
//! `InvalidParameterValueException` error.
//!
//! 4. **Error Handling**: If a checkpoint fails with "Invalid checkpoint token",
//! the error is marked as retriable so Lambda can retry with a fresh token.
//!
//! ## Requirements
//!
//! - 2.9: THE Checkpointing_System SHALL use the CheckpointToken from invocation input for the first checkpoint
//! - 2.10: THE Checkpointing_System SHALL use the returned CheckpointToken from each checkpoint response for subsequent checkpoints
//! - 2.11: THE Checkpointing_System SHALL handle InvalidParameterValueException for invalid tokens by allowing propagation for retry
pub use ;
pub use CheckpointedResult;
pub use ExecutionState;
pub use ReplayStatus;