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
gRPC入門
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
To Kawa
December 01, 2019
Technology
140
0
Share
gRPC入門
To Kawa
December 01, 2019
More Decks by To Kawa
See All by To Kawa
Coding Agentを用いた仕様駆動開発を試す中で考えたこれからのエンジニアに重要な能力
waytkheming
0
72
NotebookLMが変えるエンジニアの情報整理術
waytkheming
0
140
GoとKubernetesを用いたバッチ開発のすすめ
waytkheming
2
2.4k
Other Decks in Technology
See All in Technology
AI フレンドリーなエラー監視を TypeScript で実現する
shinyaigeek
2
250
プラットフォームエンジニア ワークショップ/ platform-workshop
databricksjapan
0
250
AIを「創る」と「使う」の循環 — HRテックが実践するリアルなAI組織実装
taketo957
0
1.3k
ルールやカスタム機能、どう使う?理想の出力を引き出すために今知りたいIBM Bob 5つの機能
muehara
1
320
新規事業を牽引する技術選定 〜フルスタックTypeScript開発の実践事例〜
nullnull
2
300
AI Testing Talks: Challenges of Applying AI in Software Testing: From Hype to Practical Use
exactpro
PRO
1
100
Spring AI × MCP 入門〜AIエージェントへのツール公開、境界設計から始める最小構成 〜
yuyamiyamoto
0
210
Dynamic Workersについて
yusukebe
2
580
探して_入れて_作って_使う_Agent_Skills___LT.pdf
peintangos
2
160
地元にいないローカルオーガナイザーの立ち回り
uvb_76
1
460
noUncheckedIndexedAccess、3時間、1万円。 / noUncheckedIndexedAccess, 3 Hours, 10,000 JPY.
kaonavi
1
250
【Gen-AX】20260530開催_JJUG CCC 2026 Spring
genax
0
410
Featured
See All Featured
Mobile First: as difficult as doing things right
swwweet
225
10k
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
240
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
200
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.9k
The Spectacular Lies of Maps
axbom
PRO
1
790
Ruling the World: When Life Gets Gamed
codingconduct
0
240
Agile that works and the tools we love
rasmusluckow
331
21k
Principles of Awesome APIs and How to Build Them.
keavy
128
17k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.5k
Building Adaptive Systems
keathley
44
3k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
150
Transcript
GoݴޠͰgRPCʹೖͯ͠Έͨ
ࣗݾհ Տ༢ढ़ً גࣜձࣾLIFULL CoEϢχοτ։ൃਪਐάϧʔϓॴଐ ৽ଔ1 ڵຯͷ͋Δ ɾϒϩοΫνΣʔϯ ɾFintech ݴޠ
Node/Solidity/PHP/Apex/Go
gRPCͱԿ͔ • Google͕։ൃͨ͠RPCݺग़ϓϩτίϧ • ϝοηʔδProtocolBuffersΛ༻͍ͯ௨৴ • HTTP/2Λ༻͍ͯฒྻݺग़ɺํݺग़ɺετϦʔϛϯά ͳͲ͕Մೳ • .protoϑΝΠϧ͔Βίʔυ͕ࣗಈੜͰ͖Δ
• GoogleͷαʔϏεͰ࣮ࡍʹΘΕ͍Δ
gRPCͱԿ͔ ΫϥΠΞϯτͱαʔόͰෳͷݴޠΛαϙʔτ͍ͯ͠Δ →ϚΠΫϩαʔϏεͳͲͱ૬ੑ͕͍͍
4ͭͷRPCํࣜ • Unary(Simple) →1 request-1 response • ServerStreaming →1 request-N
response • ClientStreaming →N request-1 response • BidirectionalStreaming →N request-N response
ϝϦοτ • REST APIΑΓURLઃܭָ͕ →protoϑΝΠϧͰAPI༷Λ໌จԽͰ͖Δ →දଆͱཪଆ͕༷ͷ͢Γ߹Θָ͕ͤ • HTTP/2Ͱฒྻݺग़ͳͲ͕Ͱ͖ΔͨΊɺߴ • ύϥϝʔλʔͷܕ͚͕Ͱ͖Δ
࡞ͷྲྀΕ 1. protoϑΝΠϧͷ࡞ 2. ᶃͰ࡞ͨ͠ϑΝΠϧΛίϯύΠϧͯ͠ɺࣗಈͰܗ ίʔυΛੜ 3. ܗίʔυΛݩʹαʔόʔˍΫϥΠΞϯτΛ࣮͢Δ
࣮ࡍʹͬͯΈΔ (Ұ൪γϯϓϧͳUnary)
protoϑΝΠϧ࡞
ίϚϯυ࣮ߦ
ίϚϯυͰੜ͞ΕΔܗϑΝΠϧ https://github.com/waytkheming/calculator-proto/blob/master/proto/calculator.pb.go
Serverଆ
Clientଆ
࣮ߦ
MongoDBΛͬͯCUIͷTwitterΈ͍ͨͳͷΛ࡞ͬͯΈͨ https://github.com/waytkheming/gwitter-proto
ࢀߟURL • gRPC Documentation https://grpc.io/docs/ • ΫοΫύου͕gRPCΛ࠾༻͢Δ·ͰαʔϏεؒ௨৴Ͱ๊͑ͯ ͍ͨ՝ͱɺRubyͰgRPCΛӡ༻͢ΔͨΊͷ https://logmi.jp/tech/articles/320715 •
gRPCͬͯԿʁ https://qiita.com/oohira/items/63b5ccb2bf1a913659d6 • gRPCʹ͓͚ΔRPCํࣜͷཧ https://qiita.com/yuzo777/items/046910c95559cf0fff68
Gopherಓͷײ
͝੩ௌ͋Γ͕ͱ͏͍͟͝·͠ ͨɻ