event sourcing concept
Persist state as an append-only log of events rather than the current values.
Persist state as an append-only log of events rather than the current values. Current state is derived by replaying the events. Audit log is the source of truth, not a side table. Time-travel debugging, retroactive feature changes, and CQRS-friendly read models all fall out naturally. Costs: schema evolution on events is a real engineering problem, replays can get expensive at scale, and 'the current value' becomes a derived concept the team has to think about rigorously. Most useful in domains where the history matters for the business, not just for ops.
Source of truth is the event log; current state is derived by replaying. Audit log built-in. Often paired with CQRS.