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.7k
Other Decks in Technology
See All in Technology
KubeCon NA 2024 Recap: How to Move from Ingress to Gateway API with Minimal Hassle
ysakotch
0
200
1等無人航空機操縦士一発試験 合格までの道のり ドローンミートアップ@大阪 2024/12/18
excdinc
0
150
レンジャーシステムズ | 会社紹介(採用ピッチ)
rssytems
0
150
Oracle Cloudの生成AIサービスって実際どこまで使えるの? エンジニア目線で試してみた
minorun365
PRO
4
280
Snykで始めるセキュリティ担当者とSREと開発者が楽になる脆弱性対応 / Getting started with Snyk Vulnerability Response
yamaguchitk333
2
180
podman_update_2024-12
orimanabu
1
260
AWS re:Invent 2024で発表された コードを書く開発者向け機能について
maruto
0
190
MLOps の現場から
asei
6
630
KnowledgeBaseDocuments APIでベクトルインデックス管理を自動化する
iidaxs
1
260
C++26 エラー性動作
faithandbrave
2
710
20241214_WACATE2024冬_テスト設計技法をチョット俯瞰してみよう
kzsuzuki
3
440
Wantedly での Datadog 活用事例
bgpat
1
430
Featured
See All Featured
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
32
2.7k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.3k
A Philosophy of Restraint
colly
203
16k
Testing 201, or: Great Expectations
jmmastey
40
7.1k
Gamification - CAS2011
davidbonilla
80
5.1k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
169
50k
Site-Speed That Sticks
csswizardry
2
190
A designer walks into a library…
pauljervisheath
204
24k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
330
21k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
Product Roadmaps are Hard
iamctodd
PRO
49
11k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
28
900
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