6 ms·
I struggle to put it into words - but I think this modern notion that we exchange language structs between processes and not arbitrary messages has lost somethi
by convolvatron 3y ago
I struggle to put it into words - but I think this modern notion that we exchange language structs between processes and not arbitrary messages has lost something valuable.
edit - I guess true interoperability? agency?
- naasking 3y agoWhat would it even mean to accept an arbitrary message? All you can do in that case is record and/or forward because the contents are unknown.
- convolvatron 3y agosorry, message defined as a format, like a tcp header that's written down and agreed upon - not message defined in some other software system like protobuf with some mapping to and from language structures
- discreteevent 3y agoProtobufs are just structured messages. They don't have anything to with language structures per se. They are semantically the same as the TCP header that's written down and agreed upon.
- convolvatron 3y agoyes. but as a matter of culture one doesn't write binary formats any longer. that's just - silly? and its not as if I don't think people should use abstractions to format messages. and as a matter of definition, yes, protobufs are just bit strings and a schema definition in a limited type language (just like xdr and asn before it). but again, as a matter of usage, we're only really supposed to use them to map to and from structs. and its not as if this doesn't work, clearly it does. as someone who used to do protocol implementation before all this, I find unsettling. and I don't know if I'm just being predudicial, or if we we are somehow losing something by adopting this model as essentially mandatory. I do find it frustrating, that when I do want certain binary properties, or I want to encode a cyclic structure in a particular way, or use a richer schema. that I have to fight upstream to not use protobufs even if they don't bring anything except a useless wrapper around a byte string I am defining anyways.
- aleksiy123 3y agoI'm not sure I understand this. Isn't protobuf just one such protocol definition. With a focus on being general. If you don't like the trade-offs it makes then you can use your own specific protocol with your own tradeoffs. But yes people will push back on you if you can't justify why that decision is better than the general solution especially if they have to use it. Imo starting with an out of the box solution as a baseline and then moving to a more specialized solution when the need arises is pretty solid decision.
- convolvatron 3y agoI think you answered my question. I’d like to say ‘what’s the most effective way to serialize this’ and everyone else wants to say ‘use protobuf unless you can come up with a really good reason not to’
- aleksiy123 3y agoYes makes sense. I think it's also about the context of what your goal is and what your eng skill set is. If you are low-level C shop that may make sense. But if you are trying to build some rpc service for usage between multiple teams and languages. Using protobufs or something similar is gonna give you more mileage.
- sly010 3y agoI feel you. Protobuf is the organizational equivalent of adding more lanes to congested roads or mandating more parking spaces. It leads to more cars.
- convolvatron 3y agoreading this didn't make sense to me...but I think you mean 'we have so much machinery here and its hard to get a handle on it - I know! lets fix it by adding more machinery'