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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
//! Database-backed persistence implementations for agent checkpointing.
//!
//! This crate provides production-ready checkpointer implementations for various
//! storage backends, allowing users to choose the persistence layer that best
//! fits their infrastructure.
//!
//! ## Available Backends
//!
//! - **Redis**: High-performance in-memory data store with optional persistence
//! - **PostgreSQL**: Robust relational database with ACID guarantees
//! - **DynamoDB**: AWS-managed NoSQL database (available in `agents-aws` crate)
//!
//! ## Feature Flags
//!
//! - `redis`: Enable Redis checkpointer
//! - `postgres`: Enable PostgreSQL checkpointer
//! - `all`: Enable all backends
//!
//! ## Examples
//!
//! ### Redis Checkpointer
//!
//! ```rust,no_run
//! use agents_persistence::RedisCheckpointer;
//!
//! #[tokio::main]
//! async fn main() -> anyhow::Result<()> {
//! let checkpointer = RedisCheckpointer::new("redis://127.0.0.1:6379").await?;
//! // Use with ConfigurableAgentBuilder
//! Ok(())
//! }
//! ```
//!
//! ### PostgreSQL Checkpointer
//!
//! ```rust,no_run
//! use agents_persistence::PostgresCheckpointer;
//!
//! #[tokio::main]
//! async fn main() -> anyhow::Result<()> {
//! let checkpointer = PostgresCheckpointer::new(
//! "postgresql://user:pass@localhost/agents"
//! ).await?;
//! // Use with ConfigurableAgentBuilder
//! Ok(())
//! }
//! ```
pub use RedisCheckpointer;
pub use PostgresCheckpointer;
// Re-export core types for convenience
pub use ;
pub use AgentStateSnapshot;