Interface EventSourcedEntity.Effect<T>

Type Parameters:
T - The type of the message that must be returned by this call
All Known Subinterfaces:
EventSourcedEntity.ReadOnlyEffect<T>
Enclosing class:
EventSourcedEntity<S,E>

public static interface EventSourcedEntity.Effect<T>
An Effect describes the actions that the Akka runtime should perform after a command handler completes. Effects are declarative instructions that tell the runtime how to persist events, send replies, or handle errors.

Event Sourced Entity effects can:

  • Persist events and send a reply to the caller
  • Reply directly to the caller without persisting events
  • Return an error message to reject the command
  • Delete the entity after persisting a final event