Add `SerializedMessageReader2`. It replaces `SerializedMessageReader` which will be removed. Summary of differences between `SerializedMessageReader` and `SerializedMessageReader2`: * The set of field handlers is a compile time parameter list. * Field numbers are compile time constants. * Field dispatch is much faster thanks to the above. * The `Context` template parameter is variadic. The `context` arguments must be lvalue references. * Natively parsed submessages are handled differently, avoiding moving message objects. * Processing nested fields involves nested function calls, rather than specifying field paths. * `SerializedMessageReader2` is not actually a class but a factory function. * Most field handlers do not get direct access to the `Reader`. `SerializedMessageWriter` and `SerializedMessageBackwardWriter` stay unchanged. `SerializedMessageRewriter` will be removed without a dedicated replacement. A cosmetic change in `SerializedMessageWriter`: pass arguments of `LengthOfString()` by const reference (they are not more efficient when moved, and it is likely a bug to `std::move` them when they are later written). PiperOrigin-RevId: 829458416
Riegeli/records is a file format for storing a sequence of string records, typically serialized protocol buffers. It supports dense compression, fast decoding, seeking, detection and optional skipping of data corruption, filtering of proto message fields for even faster decoding, and parallel encoding.
See documentation.
Riegeli file format will only change in a backward compatible way (i.e. future readers will understand current files, but current readers might not understand files using future features).
Riegeli C++ API might change in incompatible ways.