omni::telemetry::kEventProtocolLeaf

Defined in omni/structuredlog/Telemetry.h

constexpr const char *const omni::telemetry::kEventProtocolLeaf = "eventProtocol"

This setting is an optional member of the kTransmitterSetting object.

What serialization protocol is being used by the transmitter. This can be set to one of three possible (case-insensitive) values:

  • ”default”: This is the default protocol. The event will not be modified from its original generated format and content. This includes leaving the data field as a nested JSON object. This will send events in batches (as many as are available at the time) to the server with each JSON event separated by a newline (aka JSON lines format).

  • ”defaultWithStringify”: This sends batches of events at a time to the server with each JSON event separated by a newline (aka JSON lines format). Structuredlog event format is largely left as-is; the only change is that the data field’s object is stringified. This is the only difference between this protocol and the default protocol above.

  • ”NVDF”: This is also a batch serialization protocol, except that the event property names are modified to follow the expectations of the server. This flattens each event’s data payload into the event base. The time field is renamed to ts_created and its format is changed to a *nix epoch time in milliseconds. The id field is renamed to _id. All data fields are also prefixed in a Hungarian-notation style system.