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
Cacoo with Microservices
Search
Kohei
November 28, 2018
Technology
0
1.7k
Cacoo with Microservices
Kohei
November 28, 2018
Tweet
Share
More Decks by Kohei
See All by Kohei
なぜ Go はマイクロサービスのための言語なのか - Why Go is a language for microservices
cohhei
11
7.8k
Other Decks in Technology
See All in Technology
Building Scalable Backend Services with Firebase
wisdommatt
0
110
JuliaTokaiとJuliaLangJaの紹介 for NGK2025S
antimon2
1
110
自社 200 記事を元に整理した読みやすいテックブログを書くための Tips 集
masakihirose
2
330
20250116_JAWS_Osaka
takuyay0ne
2
200
[IBM TechXchange Dojo]Watson Discoveryとwatsonx.aiでRAGを実現!座学①
siyuanzh09
0
110
なぜfreeeはハブ・アンド・スポーク型の データメッシュアーキテクチャにチャレンジするのか?
shinichiro_joya
2
440
DMMブックスへのTipKit導入
ttyi2
1
110
月間60万ユーザーを抱える 個人開発サービス「Walica」の 技術スタック変遷
miyachin
1
140
iPadOS18でフローティングタブバーを解除してみた
sansantech
PRO
1
130
三菱電機で社内コミュニティを立ち上げた話
kurebayashi
1
350
シフトライトなテスト活動を適切に行うことで、無理な開発をせず、過剰にテストせず、顧客をビックリさせないプロダクトを作り上げているお話 #RSGT2025 / Shift Right
nihonbuson
3
2.1k
新卒1年目、はじめてのアプリケーションサーバー【IBM WebSphere Liberty】
ktgrryt
0
100
Featured
See All Featured
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
173
51k
Speed Design
sergeychernyshev
25
740
Thoughts on Productivity
jonyablonski
68
4.4k
Mobile First: as difficult as doing things right
swwweet
222
9k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
26
1.9k
Typedesign – Prime Four
hannesfritz
40
2.5k
Rebuilding a faster, lazier Slack
samanthasiow
79
8.8k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
33
2.7k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
251
21k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
7k
Building Adaptive Systems
keathley
38
2.4k
Transcript
Cacoo ͳͥ Kubernetes ʹΑΔ microservices ͷಓΛબΜͩͷ͔ʁ Alternative Architecture DOJO Offline
#1
ϒϩάಡΜͰͶɻ͓ΘΓ
- Cacoo ͷ։ൃνʔϜ͕ͲΜͳ՝Λ๊͍͔͑ͯͨ - Կނ microservices ͷಓΛબΜ͔ͩ - ͲΜͳٕज़ΛબΜ͔ͩ -
microservices Խͯ͠Ͳ͏͔ͩͬͨ - ݱঢ়ͷ՝
Kohei Kimura @cohhei 20181݄ Nulab ೖࣾ Cacoo νʔϜͷόοΫΤϯυΤϯδχΞ ΄΅ Go
Ԭ
Cloud-based diagrams, the easy way. Diagram maker for companies, teams,
and you
None
՝1: ϞϊϦγοΫͳΞϓϦέʔγϣϯ
ґଘؔ Ξοϓσʔτ Πϯϑϥ ։ൃޮ ௐࠪ ։ൃޮ Өڹௐࠪ ϨΨγʔ ίϛϡχ έʔγϣϯ
ϞϊϦε ίϛϡχ έʔγϣϯ ϦϙδτϦ Ωϟον Ξοϓ CI/CD εέʔϧ ίϛϡχ έʔγϣϯ
՝2: ϝϯςφϯε͕ऴྃͨ͠ ϑϨʔϜϫʔΫϥΠϒϥϦ
None
None
None
✓ αʔϏε͝ͱʹٕज़ΛબͰ͖Δ ✓ ෦తͳมߋ͕༰қʹͳΔ ✓ ʢ͏·͘ઃܭͰ͖ΕʣαʔόʔϦιʔεΛ࠷దԽͰ͖Δ ✓ ʢ͏·͘ઃܭͰ͖Εʣݎ࿚ͳγεςϜʹͳΔ microservices
ඪ: มߋΛ༰қʹ
micro services ෳͷαʔϏεͱDB ϑϩϯτΤϯυͷׂ ҟͳΔٕज़ ϨΨγʔͷߋ৽
ํɾݪଇ
- ໌֬ͳΦʔφʔγοϓ - খ͍͞΄Ͳྑ͍ - εΫϥον͔Βॻ͖ͳ͓ͯ͠ΈΔ - αʔϏεؒͷΠϯλʔϑΣʔεڧ͍ܕ͚ - ։ൃڥαʔϏε͝ͱʹࣗ༝ʹબ
- ϕετϓϥΫςΟεʹै͏
ٕज़ελοΫ
Backend/Middleware - Kubernetes - Protocol Buffers - gRPC - RabbitMQ
- Go Monitoring/Alerting - Elasticsearch + Kibana - Prometheus + Grafana - Zipkin
Dashboard Editor
Dashboard
None
Editor
None
None
Dashboard Editor
microservices ԽͷྲྀΕ
EC2ظ Kubernetesظ ECSظ - ৽͍͠ػೳΛผαʔϏεͰ - طଘػೳΛΓग़ͯ͠Dockernize - μογϡϘʔυͷαʔϏε -
ECS ͷαʔϏεΛҠߦ
region region Production Cluster Testing Cluster cacoo cacoo-beta cacoo-testing-e2e cacoo-testing-load
cacoo monitoring monitoring storages storages namespaces namespaces stress test by selenium
Scaling - Horizontal Pod Autoscaler - Cluster Autoscaler
Monitoring / Alerting
Logging stdout ops
Metrics - Prometheus & Grafana
None
Metrics - goroutines - memory ͳͲ Alerting - Pod ͷ͕ҎԼʹͳͬͨͱ͖
- Τϥʔ͕େྔʹग़ͨͱ͖ ͳͲ
Zipkin
https://zipkin.io/pages/architecture.html HTTP
Backend/Middleware - Kubernetes - Protocol Buffers - gRPC - RabbitMQ
- Go Monitoring/Alerting - Elasticsearch + Kibana - Prometheus + Grafana - Zipkin
ͰɺͲ͏ʁ
ґଘؔ ‑ - ෦తͳมߋ͘͢͠ͳͬͨ - ϏϧυɾσϓϩΠ͕ߴ - ԬνʔϜ 㱻 ւ֎νʔϜ͕ಠཱ
- Protocol Buffers ͷߋ৽ - ը໘Λލ͙ػೳͷ։ൃ ͷͱ͖
PR/issue Ͱͷίϛϡχέʔγϣϯ
νϟοτͰͷίϛϡχέʔγϣϯ
՝: ৽͍͠ෳࡶੑ
- Seasar ͷґଘ͍ͬͯΔ - αʔϏεΛͲ͜Ͱ۠Δ͔ - αʔϏεՃ͗͢͠ΔͱΠϯϑϥͷෛ୲Ὄ - ίʔυ/yamlͷੑ -
DB Λ·͍ͨͩτϥϯβΫγϣϯ
·ͱΊ
Cacoo ͷ՝ - ݹ͍ϑϨʔϜϫʔΫ - ϞϊϦγοΫͳΞϓϦέʔγϣϯͷڧ͍ґଘؔ - ଟڌͰͷ։ൃ ͦΕΒΛղܾ͢ΔͨΊʹ microservices
Խ - খ͘͞࡞ͬͯ࿈ܞ - গׂͣͭͯ͠͠ ECS ্Ͱӡ༻ - ͦͷޙ Kubernetes
- ΞϓϦέʔγϣϯͷڥքͱΦʔφʔγοϓ͕໌֬ʹ - ܧଓతͳ։ൃ͕͘͢͠ͳͬͨ - ෦తʹมߋ͍͢͠ - ߴͳϏϧυɾσϓϩΠ - ·ͩ·ͩվળ͕ඞཁ
࠷ޙʹ
ͬͯͶɻ
Appendix
Protocol Buffers - αʔϏεؒͷσʔλεΩʔϚ - .proto ϑΝΠϧʹఆٛ - Cacoo Ͱ୯Ұͷ
proto ϦϙδτϦ → git submodule Ͱ֤αʔϏεʹՃ - ιʔείʔυΛੜ
- GraphQL service -> gRPC services - gRPC services ؒ
gRPC - ΞΧϯτɺϑΥϧμʔɺਤ ͳͲ
cacoo-service-account cacoo-service-organization cacoo-service-diagram cacoo-service-folder cacoo-service-subscription cacoo-service-integration Main GraphQL service
RabbitMQ - ෳͷϝοηʔδϯάύλʔϯ - WorkQueue - Publish/Subscribe - Routing -
Topics - RPC - ΤσΟλʔͷฤूΠϕϯτΛ௨͢Δ ͳͲ - εΩʔϚ Protocol Buffers Ͱఆٛ - DB ʹฒͿॏཁͳཁૉ
Kubernetes - OSS - ΤίγεςϜͷڧ͞ - ྫ: helm