Protocol Buffers (Protobuf) is a method of serializing structured data useful for transmitting data over the wire or storing it. in this video I want to build a application with pure JSON and then rebuild the same application using protocol buffers and finally compare compare the results. I will also the pros and cons of Protocol buffers.
0:00 Intro
1:30 Write an App with JSON
8:00 ReWrite the App with Protobuf
8:20 Writing .proto file
14:00 protoc
19:00 Using protobuf structures
28:20 Pros & Cons of Protocol Buffers
Benefits of ProtoBuff
* Schema
* Binary compact size
* Language neutral
Cons
* Have to have structured data (barrier to entry)
* More involved processed for small applications.
* Have to make sure to update compiled boilerplate code (bugs, security vulnerability, etc.)
* hard to use with JSON based application (Javascript/browser)
protoc compiler
protoc --js_out=import_style=commonjs,binary:. employees.proto
npm install google-protobuf
Source Code
[ Ссылка ]
Resource
protoc download
[ Ссылка ]
protocol buffer javascript doc
[ Ссылка ]
Guys! after I uploaded the video I learned about flatbuffers which are pretty awesome.. too bad I didn’t give them an honorable mention in the video.
🏭 Software Architecture Videos
[ Ссылка ]
💾 Database Engineering Videos
[ Ссылка ]
🛰 Network Engineering Videos
[ Ссылка ]
🏰 Load Balancing and Proxies Videos
[ Ссылка ]
🐘 Postgres Videos
[ Ссылка ]
🚢Docker
[ Ссылка ]
🧮 Programming Pattern Videos
[ Ссылка ]
🛡 Web Security Videos
[ Ссылка ]
🦠 HTTP Videos
[ Ссылка ]
🐍 Python Videos
[ Ссылка ]
🔆 Javascript Videos
[ Ссылка ]
👾Discord Server [ Ссылка ]
Support me on PayPal
[ Ссылка ]
Become a Patreon
[ Ссылка ]?
Stay Awesome,
Hussein
![](https://i.ytimg.com/vi/46O73On0gyI/mqdefault.jpg)