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
REST_vs_GraphQL_今夜はご注文はどっち.pdf
Search
CypressKuo
February 23, 2021
Technology
27
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
REST_vs_GraphQL_今夜はご注文はどっち.pdf
CypressKuo
February 23, 2021
More Decks by CypressKuo
See All by CypressKuo
Deep-copying.pdf
cypresskuo
0
41
CSS_for_Web_Vitals.pdf
cypresskuo
0
46
談談_Code_review.pdf
cypresskuo
0
52
CSS_重構.pdf
cypresskuo
0
30
跟上_JS_的腳步-ES2020.pdf
cypresskuo
0
35
Core_Web_Vitals.pdf
cypresskuo
0
62
這個時代人人都知道的敏捷開發.pdf
cypresskuo
0
65
Webassembly.pdf
cypresskuo
0
19
談談_Functional_Programming.pdf
cypresskuo
0
32
Other Decks in Technology
See All in Technology
AWS ネットワーク構築でハマった(ハマりかけた) 5選とそこから得た教訓
nagisa53
4
210
Sets in Go
ramalho
1
470
【AG-UI × A2UI × MCP Apps】Generative UIをやさしく解説する
nrinetcom
PRO
1
120
モダンフロントエンド 開発研修
recruitengineers
PRO
4
630
事業価値と Engineering 2026年度版
recruitengineers
PRO
49
23k
【CEDEC2026】次世代デジタルカードゲームのサーバー設計と運用 〜『Shadowverse: Worlds Beyond』の舞台裏~
cygames
PRO
1
1.3k
AIエージェントを前提としたプラットフォーム エンジニアリング:GKEで作るAgent-Ready Golden Path
legalontechnologies
PRO
2
230
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
4.9k
JavaScript 研修 (2026)
recruitengineers
PRO
2
530
FPGAが実現する遠方宇宙の高空間分解能天体撮影 -大型地上望遠鏡の視力を補正する「補償光学」とは?-
komei_mt
0
240
[しろおび夏祭り2026] チャットするAIから、作業するAIへ - 使われ方の変化と、その裏側で起きていること
kk0n
0
1.7k
TypeScript入門 2026
recruitengineers
PRO
3
570
Featured
See All Featured
Joys of Absence: A Defence of Solitary Play
codingconduct
1
430
Statistics for Hackers
jakevdp
799
230k
Building Adaptive Systems
keathley
44
3.2k
How to Ace a Technical Interview
jacobian
281
24k
Accessibility Awareness
sabderemane
1
170
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
659
62k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
560
A Modern Web Designer's Workflow
chriscoyier
698
190k
A Soul's Torment
seathinner
6
3.4k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
620
Digital Ethics as a Driver of Design Innovation
axbom
PRO
1
360
Test your architecture with Archunit
thirion
1
2.3k
Transcript
The material contained in this documentation is proprietary and confidential
to PIXNET. Copies are made available on the basis that use is limited to the sole purpose of evaluating PIXNET’s capabilities. It is not permissible to use, modify, copy or disclose any information contained in this presentation document for any other purpose without the express written permission of PIXNET. If you are not the intended recipient of this material you are requested to take immediate steps to destroy it. Copyright © 2018 PIXNET. All rights reserved. REST vs GraphQL 今夜はご注文はどっち cypresskuo @JAAD例會 2020/10/06
RESTful API 特性 • 動詞 + 受詞 • 冪等性(Idempotent) •
回傳狀態碼 • 無狀態
RESTful API 優點 • 簡單且統一的 API 接口 • 降低系統資料之間的耦合性 •
好維護、除錯(搭配 Status Code) • 實做 Cache 較簡單(冪等性)
RESTful API 缺點 • 低耦合性 -> 高鬆散 • 資料重覆 •
資料溢出
GraphQL • 2012 年 Facebook 發明了 GraphQL • 2015 年開源
• 2018 年 Facebook 將 GraphQL 項目轉移到新成立的 GraphQL 基金會(隸 屬於非營利性的 Linux 基金會)
GraphQL 特性 • 單一個 API 接口 • 始終使用 POST 請求
• 資料需求驅動設計(Driven by data requirement) • 強型別
GraphQL 特性 https://www.example.com/api/graphql
GraphQL 特性
GraphQL 優點 • 減少 Request 的次數 • 精準資料 • 無需為了多平台而設計多個
API 系統 • 前端控制權提升
GraphQL 架構
GraphQL 架構
GraphQL 架構
GraphQL 架構
GraphQL 缺點 • 規範少(易出現 Anti Pattern) • 學習成本高 • Cache
實作較難
REST vs GraphQL どっち
Q & A
Thanks for listening