SlideShare a Scribd company logo
1 of 15
Imal Hasaranga Perera
CEO, Treinetic (Pvt) Ltd
www.treinetic.com
Google Protocol Buffers
In Simple Terms
It is just another method of Serializing Structured data, you can think of
it as JSON or XML
Json xml
08 -56 01
Protobuf
Why Use Another One ?
I already know how to use the most popular JSON / XML formats why
should I worry about this new fancy one ?
Server to Server Communication needed.
Server to Server communication format does not need to be human
friendly
It is way faster than JSON or XML
Because google uses a binary format protobufs are super fast
0
20
40
60
80
100
120
140
Throughput ( MBs )
GRPC HTTP1.1/ JSON
Services in Many Languages ?
Developer : I wrote my REST service in java and now do I have to write a client
in python and Go as well ?, I mean it is not my responsibility !!
Java Server
Go Lang
Client
Python
Client
History of ProtoBuf
Google uses a RPC based framework called Stubby which has the ability to
handle
10,000,000,000 RPC calls per second
• In 2008 with the knowledge gained from Stubby they released google
protocol buffers as an open source project.
• However it took almost 8 years since then to release a stable version, in
2017, November Protobuf 3 released as the stable version
High-level Architecture
a = 200
Proto File
Wrap
Message
Encode
Message
Java Environment
RPC
Channel
Network UnWrap
Message
Decode
Message
RPC
Channel
C# Environment
a = 200
Sample Proto File
What is gRPC ?
gRPC is a technology that is extending the protocol buffers and providing RPC
framework
a = 200
Proto File
Wrap
Message
Encode
Message
Java Environment
RPC
Channel
Network UnWrap
Message
Decode
Message
RPC
Channel
C# Environment
a = 200
gRPC Cont.
Same IDL as Protobuffer
HTTP 2
Protobuffer 3
Cons
Transferring large data is not recommended so if really needed,
developers have to workout mechanism to do it.
There is an incident where hackers were able to reverse the messages
and generate profo file and hack a popular game you have all heard
pokemon go
 Large number of classes and may create confusion with the existing
classes
 throughput is lesser but encoding time may sometimes higher than
json for smaller messages
Any Questions ?
JSON sends in binary in the network as well so what difference the
protobuffer ?
Size : 13 bytes Size : 3 bytes
8 -56 1123 32 34 97 34 32 58 32 50 48 48 32 125

More Related Content

What's hot

Big Data Spain 2017 - Deriving Actionable Insights from High Volume Media St...
Big Data Spain 2017  - Deriving Actionable Insights from High Volume Media St...Big Data Spain 2017  - Deriving Actionable Insights from High Volume Media St...
Big Data Spain 2017 - Deriving Actionable Insights from High Volume Media St...Apache OpenNLP
 
High perf-networking
High perf-networkingHigh perf-networking
High perf-networkingmtimjones
 
Networking in Java with NIO and Netty
Networking in Java with NIO and NettyNetworking in Java with NIO and Netty
Networking in Java with NIO and NettyConstantine Slisenka
 
Embracing diversity searching over multiple languages
Embracing diversity  searching over multiple languagesEmbracing diversity  searching over multiple languages
Embracing diversity searching over multiple languagesSuneel Marthi
 
Semana Interop: Trabalhando com IronPython e com Ironruby
Semana Interop: Trabalhando com IronPython e com IronrubySemana Interop: Trabalhando com IronPython e com Ironruby
Semana Interop: Trabalhando com IronPython e com IronrubyAlessandro Binhara
 
CocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIsCocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIsTim Burks
 
GitHub Advanced Search Cheat Sheet
GitHub Advanced Search Cheat SheetGitHub Advanced Search Cheat Sheet
GitHub Advanced Search Cheat SheetSusanna Frazier
 
Jdd2014: High performance logging - Peter Lawrey
Jdd2014: High performance logging - Peter LawreyJdd2014: High performance logging - Peter Lawrey
Jdd2014: High performance logging - Peter LawreyPROIDEA
 
Europe Virtual ALT.NET - EventStore v3
Europe Virtual ALT.NET - EventStore v3Europe Virtual ALT.NET - EventStore v3
Europe Virtual ALT.NET - EventStore v3Jonathan Oliver
 
Modern webservices using gRPC and Protocol Buffers in Golang
Modern webservices using gRPC and Protocol Buffers in GolangModern webservices using gRPC and Protocol Buffers in Golang
Modern webservices using gRPC and Protocol Buffers in GolangOmidHojabri1
 
[Lucas Films] Using a Perforce Proxy with Alternate Transports
[Lucas Films] Using a Perforce Proxy with Alternate Transports[Lucas Films] Using a Perforce Proxy with Alternate Transports
[Lucas Films] Using a Perforce Proxy with Alternate TransportsPerforce
 
Netem -emulating real networks in the lab
Netem -emulating real networks in the labNetem -emulating real networks in the lab
Netem -emulating real networks in the labStephen Hemminger
 
Utilizando Filas com PHP
Utilizando Filas com PHPUtilizando Filas com PHP
Utilizando Filas com PHPIvan Rosolen
 
UNSW Australia Robocup Recap Hefei 2015
UNSW Australia Robocup Recap Hefei 2015UNSW Australia Robocup Recap Hefei 2015
UNSW Australia Robocup Recap Hefei 2015Peter Schmidt
 
Go After 4 Years in Production - QCon 2015
Go After 4 Years in Production - QCon 2015Go After 4 Years in Production - QCon 2015
Go After 4 Years in Production - QCon 2015Travis Reeder
 

What's hot (17)

Big Data Spain 2017 - Deriving Actionable Insights from High Volume Media St...
Big Data Spain 2017  - Deriving Actionable Insights from High Volume Media St...Big Data Spain 2017  - Deriving Actionable Insights from High Volume Media St...
Big Data Spain 2017 - Deriving Actionable Insights from High Volume Media St...
 
High perf-networking
High perf-networkingHigh perf-networking
High perf-networking
 
Networking in Java with NIO and Netty
Networking in Java with NIO and NettyNetworking in Java with NIO and Netty
Networking in Java with NIO and Netty
 
Embracing diversity searching over multiple languages
Embracing diversity  searching over multiple languagesEmbracing diversity  searching over multiple languages
Embracing diversity searching over multiple languages
 
Semana Interop: Trabalhando com IronPython e com Ironruby
Semana Interop: Trabalhando com IronPython e com IronrubySemana Interop: Trabalhando com IronPython e com Ironruby
Semana Interop: Trabalhando com IronPython e com Ironruby
 
CocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIsCocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIs
 
GitHub Advanced Search Cheat Sheet
GitHub Advanced Search Cheat SheetGitHub Advanced Search Cheat Sheet
GitHub Advanced Search Cheat Sheet
 
Jdd2014: High performance logging - Peter Lawrey
Jdd2014: High performance logging - Peter LawreyJdd2014: High performance logging - Peter Lawrey
Jdd2014: High performance logging - Peter Lawrey
 
Europe Virtual ALT.NET - EventStore v3
Europe Virtual ALT.NET - EventStore v3Europe Virtual ALT.NET - EventStore v3
Europe Virtual ALT.NET - EventStore v3
 
Json1
Json1Json1
Json1
 
Modern webservices using gRPC and Protocol Buffers in Golang
Modern webservices using gRPC and Protocol Buffers in GolangModern webservices using gRPC and Protocol Buffers in Golang
Modern webservices using gRPC and Protocol Buffers in Golang
 
Llnw bufferbloat
Llnw bufferbloatLlnw bufferbloat
Llnw bufferbloat
 
[Lucas Films] Using a Perforce Proxy with Alternate Transports
[Lucas Films] Using a Perforce Proxy with Alternate Transports[Lucas Films] Using a Perforce Proxy with Alternate Transports
[Lucas Films] Using a Perforce Proxy with Alternate Transports
 
Netem -emulating real networks in the lab
Netem -emulating real networks in the labNetem -emulating real networks in the lab
Netem -emulating real networks in the lab
 
Utilizando Filas com PHP
Utilizando Filas com PHPUtilizando Filas com PHP
Utilizando Filas com PHP
 
UNSW Australia Robocup Recap Hefei 2015
UNSW Australia Robocup Recap Hefei 2015UNSW Australia Robocup Recap Hefei 2015
UNSW Australia Robocup Recap Hefei 2015
 
Go After 4 Years in Production - QCon 2015
Go After 4 Years in Production - QCon 2015Go After 4 Years in Production - QCon 2015
Go After 4 Years in Production - QCon 2015
 

Similar to Google Protocol Buffers + gRPC

Data Engineering with Protobuf
Data Engineering with ProtobufData Engineering with Protobuf
Data Engineering with ProtobufThiago Baldim
 
.NET Core Today and Tomorrow
.NET Core Today and Tomorrow.NET Core Today and Tomorrow
.NET Core Today and TomorrowJon Galloway
 
What I learned about APIs in my first year at Google
What I learned about APIs in my first year at GoogleWhat I learned about APIs in my first year at Google
What I learned about APIs in my first year at GoogleTim Burks
 
REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC! REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC! QAware GmbH
 
Scaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, GoalsScaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, Goalskamaelian
 
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...apidays
 
Hacking Robotics(English Version)
Hacking Robotics(English Version)Hacking Robotics(English Version)
Hacking Robotics(English Version)Kensei Demura
 
Real-Time with Flowdock
Real-Time with FlowdockReal-Time with Flowdock
Real-Time with FlowdockFlowdock
 
PHP is the King, nodejs is the Prince and Lua is the fool
PHP is the King, nodejs is the Prince and Lua is the foolPHP is the King, nodejs is the Prince and Lua is the fool
PHP is the King, nodejs is the Prince and Lua is the foolAlessandro Cinelli (cirpo)
 
What you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyondWhat you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyondJon Galloway
 
Data Serialization Using Google Protocol Buffers
Data Serialization Using Google Protocol BuffersData Serialization Using Google Protocol Buffers
Data Serialization Using Google Protocol BuffersWilliam Kibira
 
The new (is it really ) api stack
The new (is it really ) api stackThe new (is it really ) api stack
The new (is it really ) api stackLuca Mattia Ferrari
 
The 1990s Called. They Want Their Code Back.
The 1990s Called. They Want Their Code Back.The 1990s Called. They Want Their Code Back.
The 1990s Called. They Want Their Code Back.Jonathan Oliver
 

Similar to Google Protocol Buffers + gRPC (20)

Data Engineering with Protobuf
Data Engineering with ProtobufData Engineering with Protobuf
Data Engineering with Protobuf
 
.NET Core Today and Tomorrow
.NET Core Today and Tomorrow.NET Core Today and Tomorrow
.NET Core Today and Tomorrow
 
What I learned about APIs in my first year at Google
What I learned about APIs in my first year at GoogleWhat I learned about APIs in my first year at Google
What I learned about APIs in my first year at Google
 
REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC! REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC!
 
Scaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, GoalsScaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, Goals
 
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
 
gRPC with java
gRPC with javagRPC with java
gRPC with java
 
XML-RPC and SOAP (April 2003)
XML-RPC and SOAP (April 2003)XML-RPC and SOAP (April 2003)
XML-RPC and SOAP (April 2003)
 
Hacking Robotics(English Version)
Hacking Robotics(English Version)Hacking Robotics(English Version)
Hacking Robotics(English Version)
 
Real-Time with Flowdock
Real-Time with FlowdockReal-Time with Flowdock
Real-Time with Flowdock
 
gRPC
gRPCgRPC
gRPC
 
PHP is the King, nodejs is the Prince and Lua is the fool
PHP is the King, nodejs is the Prince and Lua is the foolPHP is the King, nodejs is the Prince and Lua is the fool
PHP is the King, nodejs is the Prince and Lua is the fool
 
What you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyondWhat you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyond
 
Data Serialization Using Google Protocol Buffers
Data Serialization Using Google Protocol BuffersData Serialization Using Google Protocol Buffers
Data Serialization Using Google Protocol Buffers
 
GRPC.pptx
GRPC.pptxGRPC.pptx
GRPC.pptx
 
The new (is it really ) api stack
The new (is it really ) api stackThe new (is it really ) api stack
The new (is it really ) api stack
 
Presentation1.pptx
Presentation1.pptxPresentation1.pptx
Presentation1.pptx
 
The 1990s Called. They Want Their Code Back.
The 1990s Called. They Want Their Code Back.The 1990s Called. They Want Their Code Back.
The 1990s Called. They Want Their Code Back.
 
Web Dev 21-01-2024.pptx
Web Dev 21-01-2024.pptxWeb Dev 21-01-2024.pptx
Web Dev 21-01-2024.pptx
 
APIs Demystified
APIs DemystifiedAPIs Demystified
APIs Demystified
 

Recently uploaded

How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetEnjoy Anytime
 

Recently uploaded (20)

How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptxVulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
 

Google Protocol Buffers + gRPC

  • 1. Imal Hasaranga Perera CEO, Treinetic (Pvt) Ltd www.treinetic.com Google Protocol Buffers
  • 2. In Simple Terms It is just another method of Serializing Structured data, you can think of it as JSON or XML Json xml 08 -56 01 Protobuf
  • 3. Why Use Another One ? I already know how to use the most popular JSON / XML formats why should I worry about this new fancy one ?
  • 4. Server to Server Communication needed. Server to Server communication format does not need to be human friendly
  • 5. It is way faster than JSON or XML Because google uses a binary format protobufs are super fast 0 20 40 60 80 100 120 140 Throughput ( MBs ) GRPC HTTP1.1/ JSON
  • 6. Services in Many Languages ? Developer : I wrote my REST service in java and now do I have to write a client in python and Go as well ?, I mean it is not my responsibility !! Java Server Go Lang Client Python Client
  • 7. History of ProtoBuf Google uses a RPC based framework called Stubby which has the ability to handle 10,000,000,000 RPC calls per second • In 2008 with the knowledge gained from Stubby they released google protocol buffers as an open source project. • However it took almost 8 years since then to release a stable version, in 2017, November Protobuf 3 released as the stable version
  • 8. High-level Architecture a = 200 Proto File Wrap Message Encode Message Java Environment RPC Channel Network UnWrap Message Decode Message RPC Channel C# Environment a = 200
  • 10. What is gRPC ? gRPC is a technology that is extending the protocol buffers and providing RPC framework a = 200 Proto File Wrap Message Encode Message Java Environment RPC Channel Network UnWrap Message Decode Message RPC Channel C# Environment a = 200
  • 11. gRPC Cont. Same IDL as Protobuffer HTTP 2 Protobuffer 3
  • 12. Cons Transferring large data is not recommended so if really needed, developers have to workout mechanism to do it. There is an incident where hackers were able to reverse the messages and generate profo file and hack a popular game you have all heard pokemon go  Large number of classes and may create confusion with the existing classes  throughput is lesser but encoding time may sometimes higher than json for smaller messages
  • 13.
  • 15. JSON sends in binary in the network as well so what difference the protobuffer ? Size : 13 bytes Size : 3 bytes 8 -56 1123 32 34 97 34 32 58 32 50 48 48 32 125

Editor's Notes

  1. Connection multiplexing Serverside push http://www.http2demo.io/