Skip to content

handleCommandWithDeciderAndRetry

API reference for handleCommandWithDeciderAndRetry

@delta-base/toolkit


Function: handleCommandWithDeciderAndRetry()

Section titled “Function: handleCommandWithDeciderAndRetry()”

handleCommandWithDeciderAndRetry<State, TCommand, TEvent>(eventStore, streamId, command, decider, options?): Promise<CommandHandlerResult<State, TEvent>>

Handle command with Decider and automatic retry on version conflicts

State

TCommand extends Command

TEvent extends Readonly<{ data: EventData; metadata?: PlatformEventMetadata; type: string; }> = Readonly<{ data: EventData; metadata?: PlatformEventMetadata; type: string; }>

EventStore

string

TCommand

Decider<State, TCommand, TEvent>

DeciderCommandHandlerOptions

Promise<CommandHandlerResult<State, TEvent>>