The Talon Manual

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The data modeler supports generating objects with 4 diffferent ecodings, different encodings - Json, Protobuf, Xbuf and Xbuf2. From an API perspective the generated interfaces are functionally equivalent (with a few exceptions), but each encoding has different performance characteristics that are described in the sections below. 

...

Note also that all encoding types allow a message to be serialized to or from json as a secondary functionality. 

Protobuf

With protobuf endoding encoding objects are create with backing google protobuf generated objects. Protobuf is suitable for applications with higher performance requirements than is afforded by Json encoding. It should be used by applications with moderate to high performance requirements. 

...

  • All the benefits of Xbuf listed above plus the following
    • Fastest serialization of all the encoding types
    • Significantly lower memory footprint than the Xbuf 
    • Lower memory footprint than the Protobuf encoding type
      • Between being faster, having a lower memory footprint and being zero garbage, Xbuf2 is a better choice as an encoding type than Protobuf across all dimensions. As a result, the Protobuf encoding is likely to be deprecated or removed in the next major Talon release.
    • Offers several knobs to manage the tradeoff between performance and memory conservation
    • Offers multiple data access patterns
      • Random access (as is offered by the other encoding types)
      • Serial access 
        • Direct Deserialization: The ability to serially traverse a Google Protobuf encoded buffer and dispatch the fields to the application via a callback
        • Direct Serialization: The ability for an application to directly serialize application fields into a buffer in the Google Protobuf wire format
    • Optimized for both messages and state

...