Package-level declarations
Types
An access attribute of an aggregate (@Access): its name (AccessAttributeName), unique within the aggregate ignoring case, the type of its values, and whether it holds several of them (multiple) or one, which may be absent.
The rule of an access attribute's name (@Access): lower camel case, a lower-case letter then letters and digits (PATTERN, [a-z][A-Za-z0-9]*), at most MAX_LENGTH characters, such as department or sharedWith, and not one of the built-in attributes' names (BUILT_IN).
Where an aggregate's id comes from (me.ahoo.wow.api.aggregate.AggregateIdSource).
An aggregate of a context. Its commands are those it decides, those mounted under its routes, and its system commands: the lifecycle commands its model handles and the rebuild of its snapshots, named by their full names in the system namespace (wow.lifecycle.DeleteAggregate, wow.snapshot.Rebuild). Those are the same types for every aggregate, so they are not names within the aggregate and never conflict between aggregates; the body of each is the schema of Manifest.defs keyed by that full name (Manifest.schemaRef of it), so a client types it like a command's. queries are the read models of the aggregate a client queries (QueryManifest).
The one reader of the peer contracts on a class path: every PeerContracts.RESOURCE, one per api jar (or directory) that carries the contracts of its contexts, each parsed by the caller's JSON library into the plain tree ManifestTree.read reads, so this module stays free of one. The same contract found twice is read once. A node's contract directory and wow-client's command names both read through it.
The commands of manifests by their schemas, the one rule that names a command class: the command of the schema #/$defs/<binary name> in whichever context decides it is <context>.<aggregate>.<Command>; and their routes by their full type names, the only routes a client sends a command to (routeOf). A mounted command is only an edge's, which no one sends, and is left out. A system command (SystemCommands) is named by its system name on its target (systemCommandTypeOf): an aggregate's lifecycle commands and snapshot rebuild, and a context's schedule job commands, whose target is the context's job aggregate (<context>.schedule). On a conflict the first Manifest's wins. A node's contract directory and wow-client both name commands through it.
A command the aggregate decides, or one mounted under its routes.
The REST routes of a command, and the names they reserve.
A bounded context. errors optionally documents the domain's rejection codes, the @ErrorCode constants of its module; they are runtime strings, so the list is neither complete nor checked against what the code rejects with, and a wow.* code is not the context's.
The rule of a bounded context's name: lower-case letters, digits and hyphens, starting with a letter (PATTERN, [a-z][a-z0-9-]*), such as shop or eshop-catalog. A dot is never part of one: it separates the context from the aggregate and the type in every name built from it (context.aggregate.Command, the topics wow.<context>.<aggregate>.state, the host's wow.aggregates.[<context>.<aggregate>] keys), which a dotted context name would make ambiguous.
The contracts of a service and its peers do not hold together; problems lists each problem.
An error code a client may receive: its code, the HTTP status it is answered with, what it means, and what a retry may do (retry), after retryAfter seconds, the Retry-After of its problem: one when a retry may get past it, none otherwise. The code is the code of a CommandResult and of a problem+json body, whose type is urn:wow:error:<code> and whose retry member is retry's.
An event of the aggregate: its name in the log, its revision and former names, and its description, as for a CommandManifest.
The framework's error codes and the HTTP status each is answered with: the one table the Manifest's top-level errors (Manifest.errors) and the edge's problem+json answers both read.
The kinds of me.ahoo.wow.api.result.FunctionKind a Manifest names.
The function a subscription runs, as CommandResult.function names it.
A job of an @OnSchedule handler: its name, its default rule (cron read in zone, missed slots handled as misfire says: coalesce or catch-up) and its scope (system, tenant or sharded), each value spelled as Wow writes its enumerations. The host configures the job under wow.schedules.<name>.*: its rule, and the retries of its subscriptions.
The contract of a service: its bounded contexts, their aggregates with the commands and events they speak, and their subscriptions, with the JSON Schema 2020-12 of every payload in defs (written $defs).
The one assembly of a service's Manifest from its modules' fragments, the build's (mergeManifest) and the node's at startup alike, so the Manifest a service serves is the one its build wrote: the fragments merged (ManifestMerger), naming the service, then a subscription of another context's events by type given the aggregates the peer contracts list them under (PeerSources).
The fragments of a service contradict each other; conflicts lists every contradiction found.
The markers of Manifest.requires this reader understands: a marker names a change in what part of a Manifest means, which a reader that does not know it would misread, so ManifestTree.read refuses a Manifest that requires one outside KNOWN. A value that only widens a set, such as a new enum value, needs no marker: readers read it leniently. Format 1 has none yet.
A fragment and where it was read from, for the messages of ManifestMerger.
Assembles a service's Manifest from its modules' fragments. The build merges them into the service's manifest.json; the runtime merges the same fragments when it starts. Both refuse a conflict, so a name the runtime resolves is never ambiguous:
The JSON Schema 2020-12 of the Manifest format (Manifest.FORMAT): every object ManifestTree writes, with its keys, which of them it always writes (required: a reader may rely on them; ManifestTree.read also takes a Manifest that leaves out an empty list), and the values of each enumeration this version writes. Its objects are open, as a reader of a newer writer's Manifest reads the keys it does not know past, and an enumeration's values are those of this writer: a reader reads one it does not know leniently (ManifestTree.read).
The JSON shape of a Manifest, as a tree of plain values: a JSON object is a Map<String, Any?> (insertion ordered when written), an array a List<Any?>, and a scalar a String, Number, Boolean or null. Any JSON library writes and reads such a tree, so the Manifest's field names are defined here once and wow-manifest needs none.
The peer contracts of a context: what another service needs to know of a context to send it commands, read its published streams and follow a wait chain through it, carried by the jar of the context's api module, so a service that depends on that api knows the context with no configuration.
The aggregates a subscription of another context's events reads when its handler takes them by type without naming their aggregate (SubscriptionSource.eventSchemas): those whose events the peer contracts list under the schemas the handler takes, all of one context. Each schema names an event of exactly one aggregate; an event two aggregates list, one no contract lists, or events of several contexts are a problem, which names the candidates.
A stream of state events a context publishes for other contexts: those of its aggregate, on the Kafka topic (defaultTopic unless overridden), each with the aggregate's state after the commit unless includeState is false, for an aggregate whose state is too large (a subscriber of such a stream declares a nullable state).
The names of the query field constants of an aggregate's state: the compiler's <State>Properties in the domain module and the <Context>Contract generated into its api module from the state schema name each path of the state alike, so the two sets are the same.
A query model of an aggregate: model is QueryRoutes.SNAPSHOT, the aggregate's snapshots, when it keeps them, or QueryRoutes.EVENTS, its event streams; routes are the model's query route and the route of its capability descriptor (QueryRoutes). What a model can do (its operations, fields, limits) is not here: it depends on the query backend the service runs on, which the build does not know, and the descriptor route answers it.
The routes of an aggregate's query models.
A subscription handler's in-process retry budget as @Retry declares it: each setting null when it is not given. Durations are ISO-8601 (PT2S). recoverable, unrecoverable and systemic are the qualified names of the exception classes the handler classifies itself (@Retry(recoverable, unrecoverable, systemic)).
A parameter of a ServiceRouteManifest: a variable of its path or a query parameter (location), its schema an inline JSON Schema of a scalar ({"type":"string"}, an enum), and whether a call must give it (required; a path variable always is).
The service a merged Manifest describes; a fragment has none, and a peer contract names the service that hosts its contexts, by its name alone, when its module declares it.
A service route of a context (@ServiceRoute): a route whose handler is the service's own code. Its name is its identity within the context, for compatibility and for its generated client; route is where the edge serves it, below the context; parameters are its path variables and query parameters; request and response are the inline JSON Schemas of its body and its answer, null when it takes none or answers 204 No Content: a reference into $defs ({"$ref": "#/$defs/<key>"}), or an array of one ({"type": "array", "items": {"$ref": ...}}, "uniqueItems": true for a set), a nullable one, the body or an item, written with a null alternative (Manifest.nullableSchema). A null answer is 204 No Content, no body, so an answer's schema is never nullable itself: responseOptional says the route may answer 204 No Content instead of its response (its function returns a nullable value), where a route of no response always answers it (its function returns Unit). errors are the codes it refuses with, entries of the context's error table.
Whether the aggregate keeps snapshots (enabled), and the revision of its state's structure the snapshots are written at (stateRevision): raised, the service rebuilds the stored snapshots in place, and the compatibility gate accepts a state schema change of an aggregate whose state no one else reads (no snapshot query, no published stream with the state).
The aggregate's state: its schema, and the fingerprint a snapshot written under it carries; the fingerprint is null until the schemas are generated. In a peer contract, view is the binary name of the <State>View the api module generates of it (PeerContracts.viewsOf), which a reader finds the view by: null for a state the contract has no view of, and in a service's own Manifest.
A subscription: one handler of a processor, named processor.function.
What a subscription reads: the aggregates (by name) of context whose state events it receives, and the event names it is limited to. Empty aggregates or events mean no limit; a null context means the handler's state type is not an aggregate of the module that declares it.
Where a new subscription, one without a checkpoint, starts reading the log or the stream.
The framework's system commands as a Manifest lists them, with their routes (CommandRoutes): each named by its full system name, its body the schema of Manifest.defs keyed by that name.
Properties
The schema keyword naming the JVM class a value is written from, by its binary name: an api module's generator reads it from the contract to reference the class or copy its structure into a state view. It is the service's internals, so the public port's documents leave it out (withoutClassNames); the contract and the internal port keep it.
Functions
This Manifest without CLASS_KEYWORD in any schema of its $defs: what the public port serves.