Event sourcing
Persist every state change as an immutable event and rebuild current state by replaying them.
Instead of storing only the latest state, an event-sourced system appends each change as an event to a log; state is derived by replaying events or from snapshots. This gives a full audit trail, temporal queries and easy new projections. Costs include event schema evolution, replay performance, and a learning curve; it is best kept to the parts of a system that truly benefit.
- Type
- Architecture pattern
- Category
- Architecture
- License
- Free
- Pricing
- Free
- Level
- Advanced
- Technologies
- architecture, ddd, event-store
- Last verified
- 26 Nov 2026
What Event sourcing is used for
- Audit-critical domains (finance, ledgers)
- Rebuilding projections
- Temporal queries
Strengths
- Complete history
- Replay and new read models
Limitations
- Event versioning
- Complexity
- Querying requires projections
How it relates to other tools
- Event sourcing works with CQRS (Command Query Responsibility Segregation)
- Event sourcing works with Event-driven architecture