ClusterCodec
Reads and writes the messages between the nodes of a service as JSON: the cluster channel's ForwardCommand and ForwardReply, and the WaitSignal a node sends to the origin of a wait, reading leniently: unknown fields are ignored at every level, and an unknown status, stage or function kind of a result is read as UNKNOWN (WowJson.readerBuilder), so a node of the minor version before reads a newer one's. A command's body is the domain's, not the message's: wire writes it with exactly what its class reads (CommandBodyJson); command reads one that comes from outside its context as admission reads a port's, strictly, but for a property it lacks that holds null, which is absent (command says where not); storedCommand reads the context's own stored one as its stored events are read.
Each reader compares the formats a message carries, its own and its results' (CommandResult.format), with the one this node writes, and refuses a message of another with an UnknownFormatException: a later format is a change this node cannot read, and reading it as format 1 would act on what it misreads. The comparison is of integers already read, nothing more on the path of a forward or a signal.
The mapper is Wow's (WowJson): it registers a fixed set of modules, the Kotlin module only, and never discovers others on the class path, since the wire form is the protocol and must not depend on what a host happens to bring; and it keeps every number exact, so a forwarded command's body reaches its owner with 2.50 as 2.50.
Functions
The command wire holds, its body read as model's command type of that name by the rule admission reads a port's body with (CommandBodies.decode): a property the type does not have, or a value it cannot take, refuses it (WireCommand.Malformed, with the error a port refuses it with). A body that reaches the context from outside it, on its command topic or in a forward from another node, is input, and the owner of the command type refuses what it does not declare, as on its ports (#7303). A property the type does not have that holds null is absent, at any depth but within an object whose class has a @JsonUnwrapped property and is read through its constructor, where Jackson refuses it (CommandBodies) (#7534): the body was written by a node from an object whose class has the property, or read by a port with such a class, and the null gives nothing this node's class could keep; a port, where it can be a client's misspelt "clear it", refuses it. WireCommand.UnknownType when the model has no command type of that name. One read of the tree: the reader differs from mapper's in refusing an unknown property, but for one that holds null.
The forward bytes hold; an UnknownFormatException when it is of another format.
The reply bytes hold; an UnknownFormatException when it, or one of its results, is of another format.
The signal bytes hold; an UnknownFormatException when it, or its result, is of another format.
The signals of a request body: one signal (encode) or a batch (encodeSignals); an UnknownFormatException when one of them, or its result, is of another format.
A batch of signals to one node, a JSON array of what encode writes for each, which every node of this version reads. A batch a node refuses as malformed is sent again one signal a request, once, so that a signal it cannot read costs only itself (HttpSignalSender).
The command wire holds when it is model's context's own stored data, its body read leniently: a timer's command to an aggregate of its own context, whose body that context wrote at schedule time from its own command object, perhaps by an earlier release. It is read as the context reads its stored events, a property the command type no longer has dropped: nothing else could be meant by it, a stored schedule has no upgrade hook, and refusing it would lose the scheduled work. A body from outside the context is input, read by command; a timer's command to another context is sent there and read by its intake. Null when the model has no command type of the name.
command, of the command type named type, in its wire form, with the replyTo of a rejection, sent for the actingTenant (CommandWire.actingTenant). Its body is written with exactly what its class reads (CommandBodyJson): a write-only property in, a computed one out, a null as null (#7534, #7574).