Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Choosing the Right Tool
Search
Posedio
PRO
February 12, 2024
Programming
0
23
Choosing the Right Tool
A Comparative Look at gRPC, REST an GraphQL
Posedio
PRO
February 12, 2024
Tweet
Share
More Decks by Posedio
See All by Posedio
What is a platform?
posedio
PRO
0
47
Unsealing Vault
posedio
PRO
0
18
Modern data observability
posedio
PRO
0
16
Lost Jobs, Zombie Tasks and AirFlow Nightmares: A debugging Deep Dive
posedio
PRO
0
36
Designing Zero Trust Systems
posedio
PRO
0
29
Platform user's remorse
posedio
PRO
0
140
Go KonMari on your SQL
posedio
PRO
0
25
Rolling out digital receipts on GCP infrastructure
posedio
PRO
0
24
API First revisited - where did we take a left turn?
posedio
PRO
0
65
Other Decks in Programming
See All in Programming
Temporal Knowledge Graphで作る! 時間変化するナレッジを扱うAI Agentの世界
po3rin
4
900
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
340
ドメイン駆動設計のエッセンス
masuda220
PRO
14
5.8k
Devoxx BE - Local Development in the AI Era
kdubois
0
150
EMこそClaude Codeでコード調査しよう
shibayu36
0
460
CSC305 Lecture 11
javiergs
PRO
0
310
AkarengaLT vol.38
hashimoto_kei
1
130
マンガアプリViewerの大画面対応を考える
kk__777
0
400
SwiftDataを使って10万件のデータを読み書きする
akidon0000
0
250
Foundation Modelsを実装日本語学習アプリを作ってみた!
hypebeans
0
130
AI 駆動開発におけるコミュニティと AWS CDK の価値
konokenj
5
290
Server Side Kotlin Meetup vol.16: 内部動作を理解して ハイパフォーマンスなサーバサイド Kotlin アプリケーションを書こう
ternbusty
3
260
Featured
See All Featured
jQuery: Nuts, Bolts and Bling
dougneiner
65
7.9k
Into the Great Unknown - MozCon
thekraken
40
2.1k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
22k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
127
54k
How to Ace a Technical Interview
jacobian
280
24k
Stop Working from a Prison Cell
hatefulcrawdad
272
21k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
We Have a Design System, Now What?
morganepeng
53
7.8k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
23
1.5k
The Illustrated Children's Guide to Kubernetes
chrisshort
49
51k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.7k
Music & Morning Musume
bryan
46
6.9k
Transcript
None
Your guiding light to innovation
CHOOSING THE RIGHT TOOL: A COMPARATIVE LOOK AT GRPC, REST,
AND GRAPHQL JAVA MEETUP - VIENNA DAMJAN GJUROVSKI 21 May 2024
4 HI • Damjan Gjurovski • Dev and Ops J
• Written REST code for a long while, dabbled in GraphQL for some frontend apps and implemented (and debugged) gRPC in performance-critical applications
WHAT’S IN IT FOR ME 1. The sandbox 2. REST,
GraphQL, gRPC – what do the letters mean 3. Let’s compare them, but fairly 4.What should I use in my project?
THE SANDBOX 1
7 OUR TINY APP • Book rooms in a hotel
• Mental model • What would a database model look like • What would Java entities look like
REST, GRAPHQL, GRPC – WHAT DO THE LETTERS MEAN 2
9 REST • Representational state transfer • Resources on the
server • Identifiers • Representation over the wire • HTTP verbs to modify state
10 REST PROBLEMS • Misuse / verbs in URL •
Batch transactions • Partial data requests
11 GRAPHQL • Only request data as needed • Schema
is defined separately, and compatibility can be ensured/enforced
12 GRAPHQL PROBLEMS • Caching • Complex queries • Schema
evolution
13 GRPC • Binary protocol – super fast • Protobuf
schema is defined separately, and compatibility can be ensured/enforced • Nice features for scale
14 GRPC PROBLEMS • Remote procedure calls • Server to
server communication • Code generation / stubs • Debugging
LET'S COMPARE THEM, BUT FAIRLY 3
16 • Client – Server • Browser – Server •
API Client - Server • Server – Server • Microservices • Backend servers COMMUNICATION TYPES
17 • Lots of data • Only partially used data
• Streaming data • Little data • Data represents state DATA
18 • Security • Latency • Schema evolution NON-FUNCTIONAL REQUIREMENTS
19 HOW TO BUILD FAST ON TOP OF SLOW SYSTEMS
20 HOW TO BUILD FAST ON TOP OF SLOW SYSTEMS
WHAT SHOULD I USE IN MY PROJECT 4
22 THIS IS THE WAY • Use gRPC for critical,
complex projects • Use graphQL when you need to support multiple clients with different needs • When not sure use REST
23 WANT TO KEEP THE DISCUSSION GOING? MESSAGE ME ON
LINKEDIN!