Package akka.persistence.typed.javadsl
Class ReplicatedEventSourcedBehavior<Command,Event,State>
- java.lang.Object
-
- akka.actor.typed.Behavior<T>
-
- akka.actor.typed.internal.BehaviorImpl.DeferredBehavior<Command>
-
- akka.persistence.typed.javadsl.EventSourcedBehavior<Command,Event,State>
-
- akka.persistence.typed.javadsl.ReplicatedEventSourcedBehavior<Command,Event,State>
-
public abstract class ReplicatedEventSourcedBehavior<Command,Event,State> extends EventSourcedBehavior<Command,Event,State>
Base class for replicated event sourced behaviors.For projects using Java 17 and newer, also see
EventSourcedOnCommandBehavior
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class akka.actor.typed.Behavior
Behavior.BehaviorDecorators<Inner>, Behavior.BehaviorDecorators$
-
-
Constructor Summary
Constructors Constructor Description ReplicatedEventSourcedBehavior(ReplicationContext replicationContext)
ReplicatedEventSourcedBehavior(ReplicationContext replicationContext, java.util.Optional<BackoffSupervisorStrategy> onPersistFailure)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Behavior<Command>
apply(TypedActorContext<Command> context)
INTERNAL API: DeferredBehavior init, not for user extensionprotected ReplicationContext
getReplicationContext()
boolean
withEventPublishing()
Override and return false to disable events being published to the system event stream asPublishedEvent
after they have been persisted.-
Methods inherited from class akka.persistence.typed.javadsl.EventSourcedBehavior
commandHandler, deleteEventsOnSnapshot, Effect, emptyState, eventAdapter, eventHandler, journalPluginId, lastSequenceNumber, newCommandHandlerBuilder, newEventHandlerBuilder, newSignalHandlerBuilder, persistenceId, recovery, retentionCriteria, shouldSnapshot, signalHandler, snapshotAdapter, snapshotPluginId, snapshotSelectionCriteria, stashCapacity, tagsFor, tagsFor
-
Methods inherited from class akka.actor.typed.Behavior
BehaviorDecorators, canonicalize, existsInStack, interpretMessage, interpretSignal, isAlive, isDeferred, isUnhandled, narrow, start, validateAsInitial
-
-
-
-
Constructor Detail
-
ReplicatedEventSourcedBehavior
public ReplicatedEventSourcedBehavior(ReplicationContext replicationContext, java.util.Optional<BackoffSupervisorStrategy> onPersistFailure)
-
ReplicatedEventSourcedBehavior
public ReplicatedEventSourcedBehavior(ReplicationContext replicationContext)
-
-
Method Detail
-
apply
public Behavior<Command> apply(TypedActorContext<Command> context)
INTERNAL API: DeferredBehavior init, not for user extension- Overrides:
apply
in classEventSourcedBehavior<Command,Event,State>
-
getReplicationContext
protected ReplicationContext getReplicationContext()
-
withEventPublishing
public boolean withEventPublishing()
Override and return false to disable events being published to the system event stream asPublishedEvent
after they have been persisted.
-
-