From the course: Effective Serialization with Python

Unlock the full course today

Join today to access over 23,100 courses taught by industry experts.

Protocol buffers overview

Protocol buffers overview

- [Instructor] Protocol buffers are a binary format that has a schema. It originated from Google, and became very popular. Now it's used by many companies, mostly for server to server communication. We start by writing a schema file with a .proto extension. And then use a compiler called protoc to generate code to civilize and de-civilize objects. The protoc compiler can generate code, called bindings, to several languages. This is nice, since in today's microservice architecture, different services can be written in different languages. The protocol buffer's definition file provides a center place where all services agree on the message format. Since protocol buffers are a binary format, it's efficient in both CPU and the size of civilized data. On top of protocol buffers, there is gRPC. It's a very popular server-to-server communication protocol, again from Google. gRPC is basically protocol buffers over HTTP/2.

Contents