Event sourcing
Event sourcing is a persistence pattern in which state changes are recorded as an ordered sequence of events from which current state can be derived or reconstructed.
Functional Programming in C#, Second Edition
An event-sourced system persists state-changing events that can be replayed to reconstruct its state.
- How it is used
- Uses event sourcing as an append-only persistence model that derives entity state from state-changing events.
- How deep it goes
- Works through event persistence, state reconstruction, command and query flows, and domain-fit trade-offs.
- Examples
- Uses bank-account events and statements to demonstrate replay and views, and online auctions to assess domain fit.
- What you can do after
- Builds a basic event-sourced persistence flow from scratch, including event storage, state reconstruction, and view-model creation.
Read how Functional Programming in C#, Second Edition explains event sourcing →
Kafka for Architects
An event-sourced system persists state changes as an ordered sequence of events from which current state can be reconstructed.
- How it is used
- Uses Kafka’s retained event log as the authoritative history for reconstructing state and supporting event-driven processing.
- How deep it goes
- Explains immutable events, replay, retention, snapshots, and database trade-offs, but stops short of implementation walkthroughs.
- Examples
- Demonstrates customer-address replay and order enrichment through a change-log join.
- What you can do after
- Evaluate Kafka event-sourcing designs by balancing replayability, snapshots, query needs, retention cost, and database fit.
Akka in Action, Second Edition
Event sourcing is a persistence technique that stores state changes as an ordered sequence of events and reconstructs current state by replaying them.
- How it is used
- Uses a journal to make actor state durable and recoverable while keeping application logic expressed through messages.
- How deep it goes
- Explains commands, validation, event append, replay, immutability, and versioned deserialization; defers event-adapter details.
- Examples
- Uses Conversation actors with MessageAdded events and cargo events whose schemas gain or lose fields over time.
- What you can do after
- Operate persistent actors by validating commands, appending events, replaying journals, and accommodating event-schema versions.
Read how Akka in Action, Second Edition explains event sourcing →
Also covered in
- Build High Value Software SystemsIn early access (MEAP)
What to know first
- eventA software event is an occurrence, state change, or notification that a system can detect, record, communicate, or handle.
- stateState is information describing the condition or configuration of a system or computation at a particular time that may influence its behavior or subsequent transitions.
Related concepts
- eventuses · A software event is an occurrence, state change, or notification that a system can detect, record, communicate, or handle.
- Akka Persistenceused by · Akka Persistence is an Akka module for building actors whose state can be durably stored and recovered from persisted events or snapshots.
- append-only systemuses · A system that records new data by adding entries while preserving existing entries without modifying or removing them.
- CQRSaddressed by · CQRS is an architectural pattern that separates operations and models for changing application state from those for reading or querying it.
- event storeused by · An event store is a persistent system for recording and retrieving events.
Questions about event sourcing
What is event sourcing?
Event sourcing is a persistence pattern in which state changes are recorded as an ordered sequence of events from which current state can be derived or reconstructed.
Which Manning books explain event sourcing?
Functional Programming in C#, Second Edition, Kafka for Architects and Akka in Action, Second Edition.
What should I know before learning event sourcing?
Manning books that teach event sourcing usually introduce event and state first.
What is the difference between event sourcing and assertion-based approach?
Event sourcing is a persistence pattern in which state changes are recorded as an ordered sequence of events from which current state can be derived or reconstructed. A data persistence model that stores assertions about entities and attributes, retaining facts associated with particular time ranges.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.


