SnapshotStrategy
interface SnapshotStrategy
Strategy for managing snapshots of state aggregates. Snapshot strategies determine when and how to create snapshots based on state events. This helps optimize aggregate loading by reducing the number of events that need to be replayed.
Implementations can define custom logic for snapshot creation, such as:
Taking snapshots after a certain number of events
Taking snapshots at specific time intervals
Taking snapshots based on aggregate state changes
Author
ahoo wang