liveBook · Manning

Protocol buffer

As explained in Go in Practice, Second Edition

Protocol Buffers is a language- and platform-neutral schema system and compact binary serialization format for structured data, with support for generated code.

Protocol Buffers is a schema system and compact binary serialization format for structured messages. It formalizes cross-language API contracts, generates message and service bindings, and typically supports faster serialization than JSON. section 11.5

Chat service

A chat schema defines CommentRequest and CommentResponse messages, imports a timestamp type, and exposes RouteComments through ChatService. Generated Go and Python bindings support a Python server and Go client exchanging binary messages.

How Go in Practice, Second Edition covers it

How deep it goes
Explains schemas, generated bindings, commands, servers, clients, and trade-offs, but does not detail binary encoding internals.
Examples
Uses a proto3 chat schema, protoc generation, a Python gRPC server, and a Go client calling RouteComments.
What you can do after
Build cross-language gRPC messages and services, generate bindings, run a server, and invoke it from a client.
How it connects
Connects protobuf with gRPC, RPC, REST, JSON, serialization, code generation, and backward-compatible API contracts.

Also explained in

Compare how 10 books explain protocol buffer →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Go in Practice, Second Edition. The section links point to the parts of the book it draws on.