Data Messages

Data messages carry application-specific data defined by a DML Protocol. However, DML as a serialization system is not inherently related to the framing protocol itself, and should be considered a separate entity which is chosen due to its flexibility.

Along with the encoded DML payload, a small header provides the metadata needed for the peer to understand the message.

The "message" terminology can either stand for a data message as part of the framing protocol, which is documented here, or a DML message as a data structure encoded inside a data message. These are not to be confused with each other, see Data Management Layer for more details on the serialization system.

Structure

An encoded message always follows a fixed structure. The opcode in the frame body is always set to 0 for data messages.

OffsetTypeDescription
0x0uint8The service ID the message belongs to
0x1uint8The order number within the protocol
0x2uint16The length of the entire DML message data, including this header
0x4uint8[len]The serialized DML message data
lenuint8Trailing null byte; not considered by the length field