4 ms·
Anyone who actually knows protobuf knows this is a comically bad idea. Protobuf is not self describing, and even the types are ambiguous. And pointlessly ambigu
by 38 3y ago
Anyone who actually knows protobuf knows this is a comically bad idea. Protobuf is not self describing, and even the types are ambiguous. And pointlessly ambiguous. The spec itself admits that they have two extra bits in the wire format, either one could be used to identify embedded messages.
As someone who wrote a protobuf parser,
Please don't use protobuf for anything, ever.
- hifromwork 3y agoI'm not convinced. The ASCII representation looks human readable to me, and the associated .proto definitions will make it easy to parse in any language you want. Wire format doesn't sound relevant to the plaintext representation (or am I wrong?). I've never tried it - and I don't plan to any time soon - but it doesn't sound like a terrible idea. At least it's typed and you get a parser for free.
- signa11 3y agofta ‘’’ But, hey, if you're already paying the price of using protobuf in your projects for some other reason, then why not use it for config storage, too? ‘’’ seems, imo, to be the most important point. otherwise, using it as a config replacement seems suspect.
- signa11 3y agoexactly ! and imo, this is way better than toml :)
- Shorel 3y agoThis looks much better than JSON. That makes it a winner. Your comment just reminds me of perfect being the enemy of good.
- moomin 3y agoI’m not sure why you think config files should be self-describing?
- 38 3y agoI think serialization formats should be self-describing.