Package akka.persistence.typed.internal
Interface StashManagement<C,E,S>
-
public interface StashManagement<C,E,S>INTERNAL API: Stash management for persistent behaviors
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ActorContext<InternalProtocol>context()booleanisInternalStashEmpty()booleanisStashEmpty()booleanisUnstashAllInProgress()voidlogStashMessage(InternalProtocol msg, StashBuffer<InternalProtocol> buffer)voidlogUnstashAll()voidlogUnstashMessage(StashBuffer<InternalProtocol> buffer)akka.persistence.typed.internal.BehaviorSetup<C,E,S>setup()voidstash(InternalProtocol msg, StashBuffer<InternalProtocol> buffer)Behavior<InternalProtocol>stashInternal(InternalProtocol msg)Stash a command to the internal stash buffer, which is used while waiting for persist to be completed.akka.persistence.typed.internal.StashStatestashState()voidstashUser(InternalProtocol msg)Stash a command to the user stash buffer, which is used whenStasheffect is used.Behavior<InternalProtocol>tryUnstashOne(Behavior<InternalProtocol> behavior)tryUnstashOneis called at the end of processing each command, published event, or when persist is completedvoidunstashAll()SubsequenttryUnstashOnewill drain the user stash buffer before using the internal stash buffer.
-
-
-
Method Detail
-
context
ActorContext<InternalProtocol> context()
-
isInternalStashEmpty
boolean isInternalStashEmpty()
-
isStashEmpty
boolean isStashEmpty()
- Returns:
- false if
tryUnstashOnewill unstash a message
-
isUnstashAllInProgress
boolean isUnstashAllInProgress()
-
logStashMessage
void logStashMessage(InternalProtocol msg, StashBuffer<InternalProtocol> buffer)
-
logUnstashAll
void logUnstashAll()
-
logUnstashMessage
void logUnstashMessage(StashBuffer<InternalProtocol> buffer)
-
stash
void stash(InternalProtocol msg, StashBuffer<InternalProtocol> buffer)
-
stashInternal
Behavior<InternalProtocol> stashInternal(InternalProtocol msg)
Stash a command to the internal stash buffer, which is used while waiting for persist to be completed.
-
stashState
akka.persistence.typed.internal.StashState stashState()
-
stashUser
void stashUser(InternalProtocol msg)
Stash a command to the user stash buffer, which is used whenStasheffect is used.
-
tryUnstashOne
Behavior<InternalProtocol> tryUnstashOne(Behavior<InternalProtocol> behavior)
tryUnstashOneis called at the end of processing each command, published event, or when persist is completed
-
unstashAll
void unstashAll()
SubsequenttryUnstashOnewill drain the user stash buffer before using the internal stash buffer. It will unstash as many commands as are in the buffer whenunstashAllwas called, i.e. if subsequent commands stash more, those will not be unstashed untilunstashAllis called again.
-
-