5 ms·
What would be the problem with using something like protobufs? To write the configuration, you can use whatever language you want, what matters are the outputs
by vander_elst 5y ago
What would be the problem with using something like protobufs? To write the configuration, you can use whatever language you want, what matters are the outputs anyway. The outputs are stored by automation in text format so that they can be better inspected. The programs that use such configuration have the advantage of knowing the schema of the configuration and directly parse it avoiding possible typing problems. The nice thing is that you can use the same language to write the programs and the configuration.
- mikojan 5y agoprotobuf may very well be total overkill. What you wanted to do was strongly type your configuration. What you get is a complete RPC layer. This might not even be warranted when inter-process communication is a primary concern. After all, there's nothing inherently wrong with using whatever data transfer mechanism your standard lib provides. It's not just protobuf though. Almost every data format for serializing structured data suffers from pushing a jungle on you when all you asked for was a banana. The least invasive format I know of is FlatBuffers[0]. Doesn't push RPC on you. Allows you to parse a message even if you do not know this specific message's data structure in advance (like JSON). [0]: https://google.github.io/flatbuffers/ https://google.github.io/flatbuffers/
- vander_elst 5y ago1. As said in the original comment, it doesn't necessarily have to be protobuf, but just a data serialization system. 2. Protobuf per se is just a serialization system, it does not push RPC "Protocol buffers are Google's language-neutral, platform-neutral, extensible mechanism for serializing structured data – think XML, but smaller, faster, and simpler." [0]. It can be used in combination with RPC systems, but does not have to. [0] https://developers.google.com/protocol-buffers https://developers.google.com/protocol-buffers