#gRPC
gRPC is a high-performance RPC framework built on HTTP/2 and Protocol Buffers. Articles cover gRPC service design in Go, performance benchmarking against GraphQL, and the patterns that make gRPC suitable for low-latency inter-service communication in distributed systems.
13 posts tagged with grpc. ← All posts
A2A defines what agents exchange independently of how it travels, so the same operations work over JSON-RPC, gRPC, or plain REST — and the operation set is small enough to hold in your head.
A2A defines what agents exchange independently of how it travels, so the same operations work over JSON-RPC, gRPC, or plain REST — and the operation set is small enough to hold in your head.
A gRPC service that works on localhost is a long way from one that runs reliably at scale. Production raises questions localhost never does: how do calls get load-balanced when connections are long-lived? How do you secure them, expose them to browsers, observe them, and evolve the contract without breaking anyone? This closing post covers what it takes to run gRPC for real.
A gRPC service that works on localhost is far from one that runs reliably at scale. Production raises questions localhost never does: how do calls get load-balanced when connections are long-lived? How do you secure them, expose them to browsers, observe them, and evolve the contract without breaking anyone? This closing post covers running gRPC for real.
When REST is the wrong shape for the problem, GraphQL and gRPC each fix a different pain — and each buys that fix with a new cost you have to design around.
When REST isn't the right shape: GraphQL (client-selected fields, and its N+1 / caching / complexity costs) and gRPC (Protobuf, HTTP/2, streaming, codegen) — plus a decision framework for REST vs GraphQL vs gRPC.
Streaming is gRPC's most powerful feature and its most misused. Sending a stream of messages sounds simple until one side produces faster than the other can consume — then, without flow control, you get unbounded memory growth and crashes. gRPC inherits HTTP/2's flow control to prevent exactly this. Understanding backpressure is the difference between streaming that scales and streaming that falls over under load.
Streaming is gRPC's most powerful feature and its most misused. Sending a stream sounds simple until one side produces faster than the other consumes — then, without flow control, you get unbounded memory growth and crashes. gRPC inherits HTTP/2's flow control to prevent exactly this. Backpressure is the difference between streaming that scales and streaming that falls over.
Errors are part of every API's contract, and gRPC has a specific, structured model for them: a fixed set of status codes, a message, and optional rich details — not the HTTP status codes you know from REST. Using this model well is what makes failures actionable for callers instead of opaque. Getting it wrong turns every error into a debugging session.
Errors are part of every API's contract, and gRPC has a specific, structured model: a fixed set of status codes, a message, and optional rich details — not the HTTP status codes you know from REST. Using it well makes failures actionable for callers instead of opaque; getting it wrong turns every error into a debugging session.
A production RPC is more than a request and a response. Every call should carry a deadline so it can't hang forever, metadata for cross-cutting concerns like auth and tracing, and it should pass through interceptors that apply logging, authentication, and metrics uniformly. These three mechanisms are how a gRPC system becomes observable, secure, and resilient — and they're the pieces beginners most often skip.
A production RPC is more than a request and response. Every call should carry a deadline so it can't hang forever, metadata for cross-cutting concerns like auth and tracing, and pass through interceptors that apply logging, authentication, and metrics uniformly. These three mechanisms make a gRPC system observable, secure, and resilient.
The magic that makes an RPC feel like a local function call is code generation. You run a compiler over your `.proto` file and out come typed classes and methods for your language — the client stub you call and the server interface you implement. Understanding what's generated, and the boundary between generated and hand-written code, is what turns gRPC from a black box into a tool you control.
The magic that makes an RPC feel like a local function call is code generation. Run a compiler over your .proto and out come typed classes and methods — the client stub you call and the server interface you implement. Understanding what's generated, and the boundary between generated and hand-written code, turns gRPC from a black box into a tool you control.
gRPC isn't just request-and-response. Because it rides on HTTP/2, it offers four distinct call patterns: unary, server streaming, client streaming, and bidirectional streaming. Each fits a different shape of problem, and choosing the right one is a real design decision — it changes how your API feels, how it performs, and how it handles data that arrives over time rather than all at once.
gRPC isn't just request-and-response. Riding on HTTP/2, it offers four call patterns: unary, server streaming, client streaming, and bidirectional. Each fits a different shape of problem, and choosing the right one is a real design decision — it changes how your API feels, performs, and handles data that arrives over time rather than all at once.
Protocol Buffers are the foundation gRPC is built on — both the language you write your API contract in and the binary format your data travels as. A `.proto` file is a strict, versioned schema; the encoding is a compact, tag-based binary that's a fraction of JSON's size. Understanding both halves — the schema language and how it serializes — is what lets you design APIs that stay compatible as they evolve.
Protocol Buffers are gRPC's foundation — both the language you write your API contract in and the compact binary format your data travels as. A .proto file is a strict, versioned schema; the encoding is tag-based binary a fraction of JSON's size. Understanding both halves is what lets you design APIs that stay compatible as they evolve.
REST won the public web, but inside a system — between the dozens of services that make up a modern backend — a different model dominates: RPC. Instead of modeling everything as resources and verbs over HTTP, you call a remote function as if it were local. gRPC is the modern, high-performance realization of that idea, built on Protocol Buffers and HTTP/2. Understanding why it exists explains when to reach for it over REST.
REST won the public web, but inside a system — between the dozens of services in a modern backend — RPC dominates: you call a remote function as if it were local. gRPC is the modern, high-performance realization of that idea, built on Protocol Buffers and HTTP/2. Understanding why it exists explains when to reach for it over REST.
This lesson swaps the LLM behind an agent for another agent, reached over the A2A protocol instead of a model API.
Back a Go agent with another agent over the A2A protocol: resolve the remote card, open a gRPC client, and wrap it with a2aprovider.NewAgent.
The Picnic social platform served 1M+ users across a graph of Go microservices behind a GraphQL gateway. The latency win came from a counter-intuitive move: fewer services, tighter contracts.
100K+ votes, 10K+ concurrent users during a live AFL Brownlow Medal broadcast. The architecture: Go on Cloud Run, GraphQL + gRPC behind a CDN, vote integrity through Cloud KMS + Security Command Center. Notes on what makes a live-broadcast load shape unusual.
All posts on this site are written by Pratik Dhanave, an Agentic AI Architect with 7+ years building production distributed systems, multi-agent AI platforms, and cloud-native infrastructure. About the author → Each article includes working code, architecture diagrams, and references to the specific frameworks and standards discussed. Browse all posts or explore related topics using the tag cloud above.