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
//! Transaction Management
//!
//! Provides ACID transaction guarantees with WAL-based durability.
//!
//! # Architecture
//!
//! ```text
//! ┌─────────────────────────────────────────────────────────────────┐
//! │ Transaction Manager │
//! ├─────────────────────────────────────────────────────────────────┤
//! │ begin() → TxnHandle │
//! │ commit(TxnHandle) → Result<(), Error> │
//! │ abort(TxnHandle) │
//! └─────────────────────────────────────────────────────────────────┘
//! │
//! ┌──────────────────┼──────────────────┐
//! ▼ ▼ ▼
//! ┌─────────┐ ┌─────────┐ ┌─────────┐
//! │ WAL │ │ MVCC │ │ Lock │
//! │ Logger │ │ Store │ │ Manager │
//! └─────────┘ └─────────┘ └─────────┘
//! ```
//!
//! # Isolation Levels
//!
//! - **Read Committed**: See committed changes from other transactions
//! - **Snapshot Isolation**: See consistent snapshot from transaction start
//! - **Serializable**: Full serializability (not yet implemented)
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use is_visible;