3 ms·
Here's some tech we are thinking about: * gRPC. Good attempt at solving cross-language RPC. Downsides: Alpha quality; Protobuf requires build steps on the clie
by lobster_johnson 11y ago
Here's some tech we are thinking about:
* gRPC. Good attempt at solving cross-language RPC. Downsides: Alpha quality; Protobuf requires build steps on the client side (codegen, schema versioning); Doesn't yet solve discovery or fault tolerance; 3.0 beta is required if you want to ship free-form blobs of data around.
* Protobuf: Similar to gRPC.
* NATS. Fast in-memory messaging broker which seems suitable for RPC. In particular, this solves the discoverability issue, since services are simply topics. Downsides: Something of a single point of failure. Also, we still need to add an HTTP compatibility layer for browser clients, and we'd still need to write bindings for each language we use so that services can declare endpoints, and clients can talk to them, without using the NATS library directly. Fault tolerance also needs to built into this glue. Not saying it wouldn't be a nice open source project, though.
* Thrift. Similar to gRPC/Protobuf. Requires schemas. We've talked to people who use this in production, and they're not too happy. Seems rather biased towards the Java universe.
- rdli 11y agoprotobuf and Thrift are serialization formats and an alternative to JSON, not RPC.
- lobster_johnson 11y agoI know, I should have said "Protobuf + custom connection handling". Thrift does come with RPC client/server code. You can choose between different transports. Example [1]. [1] https://github.com/apache/thrift/blob/master/lib/nodejs/examples/client.js https://github.com/apache/thrift/blob/master/lib/nodejs/exam...