CommandStage

Enumeration of command processing stages.

CommandStage defines the various stages a command goes through during processing, from being sent to the bus until all related processing (events, projections, sagas) is complete. Each stage has dependencies on previous stages.

See also

Entries

Link copied to clipboard

Command has been sent to the command bus/queue.

Link copied to clipboard

Command has been processed by the aggregate root.

Link copied to clipboard

Aggregate snapshot has been generated.

Link copied to clipboard

Command-generated events have been projected.

Link copied to clipboard

Command-generated events have been handled by event processors.

Link copied to clipboard

Command-generated events have been handled by sagas.

Properties

Link copied to clipboard

Returns a representation of an immutable list of all enum entries, in the order they're declared.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract val previous: List<CommandStage>

List of prerequisite stages that must complete before this stage.

Link copied to clipboard
open val shouldWaitFunction: Boolean = false

Whether this stage involves waiting for function execution.

Functions

Link copied to clipboard
fun isPrevious(processingStage: CommandStage): Boolean

Checks if the given stage is a prerequisite for this stage.

Link copied to clipboard
fun shouldNotify(processingStage: CommandStage): Boolean

Determines if notification should be sent for this stage.

Link copied to clipboard
fun CommandStage.toWaitingChainTail(function: NamedFunctionInfoData = NamedFunctionInfoData.EMPTY): WaitingChainTail

Converts a CommandStage to a WaitingChainTail with optional function criteria. For stages that require function waiting, the provided function is used. For stages that don't require function waiting, an empty function is used.

Link copied to clipboard

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared.