4 ms·
JSON or graphql. Personally I think the typing, API compatibility and extensive language support make protobuffers currently the winner though, despite the wart
by tlarkworthy 8y ago
JSON or graphql. Personally I think the typing, API compatibility and extensive language support make protobuffers currently the winner though, despite the warts
- vthallam 8y agoHow would graphql help reduce the latency of API calls between services?
- hardwaresofton 8y agoI'm no GraphQL expert/fan but one example is requesting only the data you need -- you can cut down on what you have to send over the wire which is at least guaranteed to help some. Also, the nested query structure can save what would have normally been multiple requests with a by-the-book RESTful HATEOAS setup.
- FridgeSeal 8y agoNeither of those are binary formats though, and if I’m picking up a binary format like Protobuffers it’s probably because I want the performance benefits. Personally, these days I’m taking the approach of just outright avoiding pretty much anything google does. Either because it solves a problem only they have, or they’ll probably just drop it out of the blue one day. Or like Tensorflow, it’s fucking impossible to get your head around because their documentation seems to be written with the goal of being maximally confusing.
- sonnyblarney 8y agoI like GraphQL schema, but it would have to have a standardized serialization aspect. Moreover, it really is designed for querying and has a bunch of stuff totally irrelevant to data. But I agree ... I almost wish they'd finish it off and go for full on serialization. That said, it may not be that-that hard, a serialization spec can be pretty short if need be. Certainly one could 'roll one's own' for a mid-sized project if need be.