StatelessSagaFunctionRegistrar

class StatelessSagaFunctionRegistrar(commandGateway: CommandGateway, commandMessageFactory: CommandMessageFactory, actual: MessageFunctionRegistrar<MessageFunction<Any, DomainEventExchange<*>, Mono<*>>> = SimpleMessageFunctionRegistrar()) : AbstractEventFunctionRegistrar

Registrar for stateless saga functions that creates StatelessSagaFunction instances from processors annotated with saga metadata.

Constructors

Link copied to clipboard
constructor(commandGateway: CommandGateway, commandMessageFactory: CommandMessageFactory, actual: MessageFunctionRegistrar<MessageFunction<Any, DomainEventExchange<*>, Mono<*>>> = SimpleMessageFunctionRegistrar())

Properties

Link copied to clipboard

The underlying message function registrar (default: SimpleMessageFunctionRegistrar)

Link copied to clipboard
open override val functions: Set<MessageFunction<Any, DomainEventExchange<*>, Mono<*>>>

The set of all registered functions.

Functions

Link copied to clipboard
open override fun register(function: MessageFunction<Any, DomainEventExchange<*>, Mono<*>>)

Registers a message function.

Link copied to clipboard
fun registerProcessor(processor: Any)

Registers an event processor.

Link copied to clipboard
open override fun resolveProcessor(processor: Any): Set<MessageFunction<Any, DomainEventExchange<*>, Mono<*>>>

Resolves the processor by extracting saga metadata and creating stateless saga functions. This method parses the processor's class for saga annotations and wraps the resulting message functions with StatelessSagaFunction to handle command execution.

Link copied to clipboard

Finds all functions that support processing the given message.

Link copied to clipboard
open override fun unregister(function: MessageFunction<Any, DomainEventExchange<*>, Mono<*>>)

Unregisters a message function.