Package-level declarations

Types

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Command Gateway .

Link copied to clipboard
Link copied to clipboard
data class CommandResult(val stage: CommandStage, val aggregateId: String, val contextName: String, val processorName: String, val tenantId: String, val requestId: String, val commandId: String, val errorCode: String = ErrorCodes.SUCCEEDED, val errorMsg: String = ErrorCodes.SUCCEEDED_MESSAGE, val bindingErrors: List<BindingError> = emptyList(), val result: Map<String, Any> = emptyMap()) : CommandId, TenantId, RequestId, ErrorInfo, ProcessorInfo, CommandResultCapable
Link copied to clipboard
Link copied to clipboard
class CommandResultException(val commandResult: CommandResult, cause: Throwable? = null) : WowException
Link copied to clipboard
class CommandValidationException(val command: Any, errorMsg: String = "Command validation failed.", cause: Throwable? = null, val bindingErrors: List<BindingError> = emptyList()) : WowException, ErrorInfo
Link copied to clipboard
class DefaultCommandGateway(commandWaitEndpoint: CommandWaitEndpoint, commandBus: CommandBus, validator: Validator, idempotencyCheckerProvider: AggregateIdempotencyCheckerProvider, waitStrategyRegistrar: WaitStrategyRegistrar) : CommandGateway, CommandBus
Link copied to clipboard
class DuplicateRequestIdException(val aggregateId: AggregateId, val requestId: String, errorMsg: String = "Duplicate request ID[", cause: Throwable? = null) : WowException, NamedAggregate
Link copied to clipboard
class InMemoryCommandBus(val sinkSupplier: (NamedAggregate) -> Sinks.Many<CommandMessage<*>> = { Sinks.many().unicast().onBackpressureBuffer() }) : InMemoryMessageBus<CommandMessage<*>, ServerCommandExchange<*>> , LocalCommandBus

InMemoryCommandBus .

Link copied to clipboard
class LocalFirstCommandBus(val distributedBus: DistributedCommandBus, val localBus: LocalCommandBus = InMemoryCommandBus()) : CommandBus, LocalFirstMessageBus<CommandMessage<*>, ServerCommandExchange<*>>
Link copied to clipboard
class SimpleClientCommandExchange<C : Any>(val message: CommandMessage<C>, val waitStrategy: WaitStrategy, val attributes: MutableMap<String, Any> = ConcurrentHashMap()) : ClientCommandExchange<C>
Link copied to clipboard
data class SimpleCommandMessage<C : Any>(val id: String = GlobalIdGenerator.generateAsString(), val header: Header = DefaultHeader.empty(), val body: C, val aggregateId: AggregateId, val requestId: String = id, val aggregateVersion: Int? = null, val name: String = body.javaClass.toName(), val isCreate: Boolean = false, val allowCreate: Boolean = false, val createTime: Long = System.currentTimeMillis()) : CommandMessage<C> , NamedAggregate
Link copied to clipboard
class SimpleServerCommandExchange<C : Any>(val message: CommandMessage<C>, val attributes: MutableMap<String, Any> = ConcurrentHashMap()) : ServerCommandExchange<C>

Properties

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
fun <C : Any> C.toCommandMessage(id: String = GlobalIdGenerator.generateAsString(), requestId: String? = null, aggregateId: String? = null, tenantId: String? = null, aggregateVersion: Int? = null, namedAggregate: NamedAggregate? = null, header: Header = DefaultHeader.empty(), createTime: Long = System.currentTimeMillis(), upstream: DomainEvent<*>? = null): CommandMessage<C>
Link copied to clipboard
fun Throwable.toResult(commandMessage: CommandMessage<*>, contextName: String = commandMessage.contextName, processorName: String, stage: CommandStage = CommandStage.SENT, result: Map<String, Any> = emptyMap()): CommandResult