Companion

Properties

Link copied to clipboard

The names of the request facts admission derives from the caller (factsOf): a command's headers take them from its caller alone, in place of any of the same name its request carries.

Link copied to clipboard
const val MAX_FACT_LENGTH: Int = 512

The most characters of one request fact a command records; the rest is cut off.

Functions

Link copied to clipboard
fun admit(type: AggregateType, caller: Caller, target: TargetScope?, named: String?, tenants: TenantPolicy, called: Boolean = false, acting: String? = null): CallerAnswer

The admission of a command of type that caller sends, acting in target when it names one, to an aggregate whose ref names the tenant named (null for none), or why it is refused:

Link copied to clipboard

The request facts of caller: its application as RequestFacts.APP_ID when it has one, cut to MAX_FACT_LENGTH characters, since a fact lands in the immutable log.

Link copied to clipboard
fun of(caller: Caller, target: TargetScope? = null, tenantId: String = target?.tenantId ?: caller.tenantId): CallerAdmission

The admission of a command of caller, acting in target when given (a crossing Wow-Scope, a call's root), else in its own scope, and in the target's tenant, else the caller's (tenantId for a type of no fixed tenant). Whether the caller may send it there is admit's to answer.