Package akka.persistence.typed.telemetry
Class EmptyEventSourcedBehaviorInstrumentation
- java.lang.Object
-
- akka.persistence.typed.telemetry.EmptyEventSourcedBehaviorInstrumentation
-
- All Implemented Interfaces:
EventSourcedBehaviorInstrumentation
- Direct Known Subclasses:
EmptyEventSourcedBehaviorInstrumentation$
public class EmptyEventSourcedBehaviorInstrumentation extends java.lang.Object implements EventSourcedBehaviorInstrumentation
INTERNAL API
-
-
Constructor Summary
Constructors Constructor Description EmptyEventSourcedBehaviorInstrumentation()
EmptyEventSourcedBehaviorInstrumentation(ActorSystem<?> system)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
actorInitialized(ActorRef<?> actorRef)
Initialize state for an EventSourcedBehavior actor.void
afterRequestRecoveryPermit(ActorRef<?> actorRef, java.lang.Object context)
Record after a recovery permit is requested.java.lang.Object
beforeRequestRecoveryPermit(ActorRef<?> actorRef)
Record before a recovery permit is requested.scala.collection.immutable.Seq<java.lang.String>
dependencies()
Optional dependencies for this instrumentation.java.lang.Object
persistEventCalled(ActorRef<?> actorRef, java.lang.Object event, java.lang.Object command)
Record persist event.void
persistEventDone(ActorRef<?> actorRef, java.lang.Object context)
Record event is written and the registered callback is called.java.lang.Object
persistEventWritten(ActorRef<?> actorRef, java.lang.Object event, java.lang.Object context)
Record event is written but the registered callback has not been called yetvoid
persistFailed(ActorRef<?> actorRef, java.lang.Throwable throwable, java.lang.Object event, long seqNr, java.lang.Object context)
Record persistence persist failure.void
persistRejected(ActorRef<?> actorRef, java.lang.Throwable throwable, java.lang.Object event, long seqNr, java.lang.Object context)
Record persistence persist failure.void
recoveryDone(ActorRef<?> actorRef)
Record persistence recovery done.void
recoveryFailed(ActorRef<?> actorRef, java.lang.Throwable throwable, java.lang.Object event)
Record persistence recovery failure.void
recoveryStarted(ActorRef<?> actorRef)
Record persistence recovery started.
-
-
-
Constructor Detail
-
EmptyEventSourcedBehaviorInstrumentation
public EmptyEventSourcedBehaviorInstrumentation()
-
EmptyEventSourcedBehaviorInstrumentation
public EmptyEventSourcedBehaviorInstrumentation(ActorSystem<?> system)
-
-
Method Detail
-
actorInitialized
public void actorInitialized(ActorRef<?> actorRef)
Description copied from interface:EventSourcedBehaviorInstrumentation
Initialize state for an EventSourcedBehavior actor.- Specified by:
actorInitialized
in interfaceEventSourcedBehaviorInstrumentation
-
beforeRequestRecoveryPermit
public java.lang.Object beforeRequestRecoveryPermit(ActorRef<?> actorRef)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record before a recovery permit is requested.- Specified by:
beforeRequestRecoveryPermit
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery permit is about to be requested- Returns:
- context that will be passed to
afterRequestRecoveryPermit
-
afterRequestRecoveryPermit
public void afterRequestRecoveryPermit(ActorRef<?> actorRef, java.lang.Object context)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record after a recovery permit is requested.- Specified by:
afterRequestRecoveryPermit
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery permit is requestedcontext
- returned bybeforeRequestRecoveryPermit
-
recoveryStarted
public void recoveryStarted(ActorRef<?> actorRef)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record persistence recovery started.- Specified by:
recoveryStarted
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery is started.
-
recoveryDone
public void recoveryDone(ActorRef<?> actorRef)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record persistence recovery done.- Specified by:
recoveryDone
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery is finished.
-
recoveryFailed
public void recoveryFailed(ActorRef<?> actorRef, java.lang.Throwable throwable, java.lang.Object event)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record persistence recovery failure.- Specified by:
recoveryFailed
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery has failed.throwable
- the cause of the failure.event
- the event that was replayed, if any (otherwise null)
-
persistEventCalled
public java.lang.Object persistEventCalled(ActorRef<?> actorRef, java.lang.Object event, java.lang.Object command)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record persist event.- Specified by:
persistEventCalled
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the event will be sent to the journal.event
- the event that was submitted for persistence. For persist of several events it will be called for each event in the batch in the same order.command
- actor message (command), if any (otherwise null), for which the event was emitted.- Returns:
- context that will be passed to
persistEventWritten
-
persistEventWritten
public java.lang.Object persistEventWritten(ActorRef<?> actorRef, java.lang.Object event, java.lang.Object context)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record event is written but the registered callback has not been called yet- Specified by:
persistEventWritten
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the event has been successfully persisted.event
- the event that was stored in the journal.context
- context returned bypersistEventCalled
- Returns:
- context that will be passed to
persistEventDone
-
persistEventDone
public void persistEventDone(ActorRef<?> actorRef, java.lang.Object context)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record event is written and the registered callback is called.- Specified by:
persistEventDone
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the event has been successfully persisted.context
- context returned bypersistEventWritten
-
persistFailed
public void persistFailed(ActorRef<?> actorRef, java.lang.Throwable throwable, java.lang.Object event, long seqNr, java.lang.Object context)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record persistence persist failure.- Specified by:
persistFailed
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery has failed.throwable
- the cause of the failure.event
- the event that was to be persisted.seqNr
- the sequence number associated with the failurecontext
- context returned bypersistEventCalled
-
persistRejected
public void persistRejected(ActorRef<?> actorRef, java.lang.Throwable throwable, java.lang.Object event, long seqNr, java.lang.Object context)
Description copied from interface:EventSourcedBehaviorInstrumentation
Record persistence persist failure.- Specified by:
persistRejected
in interfaceEventSourcedBehaviorInstrumentation
- Parameters:
actorRef
- theActorRef
for which the recovery has failed.throwable
- the cause of the failure.event
- the event that was to be persisted.seqNr
- the sequence number associated with the failurecontext
- context returned bypersistEventCalled
-
dependencies
public scala.collection.immutable.Seq<java.lang.String> dependencies()
Description copied from interface:EventSourcedBehaviorInstrumentation
Optional dependencies for this instrumentation.Dependency instrumentations will always be ordered before this instrumentation.
- Specified by:
dependencies
in interfaceEventSourcedBehaviorInstrumentation
- Returns:
- list of class names for optional instrumentation dependencies
-
-