onEvent

open override fun onEvent(stateEventExchange: StateEventExchange<*>): Mono<Void>

Processes a state event and creates a snapshot if the version offset threshold is met. Compares the current event version with the last snapshot version to determine if a snapshot should be created.

Return

A Mono that completes when the snapshot operation (if any) is done.

Parameters

stateEventExchange

The state event exchange containing the event and aggregate state.