How does gRPC work, which call types does it have, and when should you use it?
Short answer
gRPC lets the caller invoke a method on a stub like a local call; the framework serializes with Protobuf and sends it over HTTP/2. The contract is a .proto file that generates client and server code for many languages.
3 points to say:
.protois the contract that generates code for many languages; small binary payloads, strict types.- 4 call types: unary, server streaming, client streaming, bidirectional.
- Fits internal service-to-service calls; for browsers and public APIs REST is easier. Always set a deadline; it needs an L7 LB.
Keep reading the deep dive
Create a free account to read the full explanation and follow-up questions, mark questions as studied and review them on a schedule.