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
Reactive Microservices Architecture
Search
Go Tanaka
September 09, 2016
Technology
0
220
Reactive Microservices Architecture
Go Tanaka
September 09, 2016
Tweet
Share
More Decks by Go Tanaka
See All by Go Tanaka
事業を理解するために勉強したこと
tan_go238
0
1.1k
RDRAと業務と私
tan_go238
6
4.8k
エンジニアのための情報設計入門
tan_go238
10
7.7k
JVM in Action
tan_go238
1
560
Ordinary Object Pointer in JVM
tan_go238
5
5.9k
フロントエンドの基礎知識
tan_go238
28
9.9k
たぶん便利なパターンマッチ
tan_go238
0
270
ドメイン駆動設計 第一部まとめ
tan_go238
1
370
Other Decks in Technology
See All in Technology
あの日俺達が夢見たサーバレスアーキテクチャ/the-serverless-architecture-we-dreamed-of
tomoki10
0
460
Fanstaの1年を大解剖! 一人SREはどこまでできるのか!?
syossan27
2
170
KubeCon NA 2024 Recap / Running WebAssembly (Wasm) Workloads Side-by-Side with Container Workloads
z63d
1
250
Oracle Cloudの生成AIサービスって実際どこまで使えるの? エンジニア目線で試してみた
minorun365
PRO
4
290
re:Invent をおうちで楽しんでみた ~CloudWatch のオブザーバビリティ機能がスゴい!/ Enjoyed AWS re:Invent from Home and CloudWatch Observability Feature is Amazing!
yuj1osm
0
130
権威ドキュメントで振り返る2024 #年忘れセキュリティ2024
hirotomotaguchi
2
750
Amazon VPC Lattice 最新アップデート紹介 - PrivateLink も似たようなアップデートあったけど違いとは
bigmuramura
0
200
新機能VPCリソースエンドポイント機能検証から得られた考察
duelist2020jp
0
230
DevFest 2024 Incheon / Songdo - Compose UI 조합 심화
wisemuji
0
110
.NET 9 のパフォーマンス改善
nenonaninu
0
1k
Amazon Kendra GenAI Index 登場でどう変わる? 評価から学ぶ最適なRAG構成
naoki_0531
0
110
10分で学ぶKubernetesコンテナセキュリティ/10min-k8s-container-sec
mochizuki875
3
350
Featured
See All Featured
Bash Introduction
62gerente
608
210k
Typedesign – Prime Four
hannesfritz
40
2.4k
Making the Leap to Tech Lead
cromwellryan
133
9k
What's in a price? How to price your products and services
michaelherold
243
12k
Fireside Chat
paigeccino
34
3.1k
YesSQL, Process and Tooling at Scale
rocio
169
14k
A Modern Web Designer's Workflow
chriscoyier
693
190k
Mobile First: as difficult as doing things right
swwweet
222
9k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
A designer walks into a library…
pauljervisheath
204
24k
Designing for humans not robots
tammielis
250
25k
Six Lessons from altMBA
skipperchong
27
3.5k
Transcript
Reactive Microservices Architecture @tan_go238
ࠓ͢͜ͱ
ͬ͘͘͢͟͝Γ͠·͢
ϚΠΫϩαʔϏεͷίϯηϓτ • খͯ͘͞ • ಠཱͨ͠αʔϏεͰ • ͦΕͧΕ͕ࣗͷυϝΠϯͷσʔλΛ࣋ͪ • ಠཱͯ͠ •
͞Ε͍ͯͯ • εέʔϥϒϧ • ͦͯ͠ରোੑ͕͋Δ
Monolith https://goo.gl/keQyrL
SOA Microservices Reactive Microservices ↓ ↓
Reactive Microserviceͱʁ
Reactive Manifest • ଈԠੑ • ରোੑ • ྗੑ • ϝοηʔδۦಈ
http://www.reactivemanifesto.org/ja
Reactive Microservice (Failure isolation) Bulkheading (SPOFΛͭ͘Βͳ͍)
Reactive Microservice (Own your state, Exclusively)
Reactive Microservice (Event Sourcing, CQRS)
Reactive Microservice (Asynchronous Message-Passing)
Reactive Microserviceͱʁ • ಠཱ͍ͯ͠Δ (DockerΈ͍ͨͳԾԽͱΈ߹ΘͤͯߋʹޮԽ) • ରোੑ͕͋Δ • ඇಉظϝοηʔδϯά ͍͠ɺམͪͯଞͷӨڹ͕গͳ͘ɺ
εέʔϥϒϧʹͰ͖ͯΔͷͰ͙͢ճ෮͢Δ
࣮ࡍͲ͏ͬͯ࡞Δͷʁ
Microservices Come in Systems (Service Discovery) • ͓ޓ͍ͷαʔϏεͷΞυϨεΛ͍ͬͯΔඞཁ͕͋Δ • ͦͷΛݞΘΓ͢Δͷ͕
Service Discovery • CAPఆཧͷ CP-Based ͱ AP-Based ͕͋Δ • CP-Based … Zookeeper, etcd • AP-Based … Lightbend Reactive Platform, eureka, Serf
Microservices Come in Systems (API Gateway) ΫϥΠΞϯτ͔ΒͷϦΫΤετΛड͚औͬͯɺਖ਼͍͠αʔϏε͢ ྫ) Netflix API,
Amazon API Gateway
Microservices Come in Systems (Managing Communication Patterns) • ίϛϡχέʔγϣϯύλʔϯෳࡶʹͳͬͯ͘Δ •
Publish-Subscribe ύλʔϯΛ͏ • SubscriberҎԼͷϥΠϒϥϦ͔ΒσʔλΛऔಘ͢Δ • Kafka, Amazon Kinesis, Cassandra, Riak • ·ͩෆे • σʔλετϦʔϜ … Akka Stream, Apache Camel
Microservices Come in Systems (Back-pressure) • Publish-Subscribe ͷΑ͏ͳύλʔϯͰ Pub ͷॲཧ͕
͗ͯ͢ Sub ͷॲཧ͕͍͔ͭͳ͍͜ͱ͕͋Δ • Subscriber͕͕ࣗॲཧͰ͖ΔྔΛPublisherʹϦΫΤε τΛૹΔ͜ͱͰແବͳ͘Subscriber͕ॲཧͰ͖ΔྔΛॲ ཧ͢ΔΈ • Akka Stream, RxJava, Spark Streaming, Cassandra drivers
Microservices Come in Systems (Circuit Breaker pattern) • ϦϞʔτΞΫηεͷޭʗࣦഊΛΧϯτ͠ɺ Τϥʔ
(failure rate) ͕ᮢΛ͑ͨͱ͖ʹࣗಈతʹΞΫη εΛःஅ͢ΔΈ • Netflix Hystrix, Akka (akka.pattern.CircuitBreaker)
Microservices Come in Systems (Event-Driven Architecture) • σʔλͷมߋ͙͢ଞͷαʔϏε͔Βར༻Ͱ͖ͳ͍ͱ͍͚ͳ͍ • Event
Sourcing, CQRS • Command … ෭࡞༻͕͋Δૢ࡞ • Event … Կ͔͕ىͬͨ͜ͱ͍͏ϩά (ࣄ࣮) • Event Logging and Event Streaming Product • Riak, RedBull Eventuate
Microservices Come in Systems (SAGA pattern) • ࢄγεςϜͰͷτϥϯβΫγϣϯ (Process Manager)
Summery • Reactive Microservice ʹ͢Δʹ • ҎԼͷಛੑʹݻࣥ͢Δ • ͢Δ͜ͱ •
̍αʔϏεʹ͖ͭ̍ͭͷͷΈ • ഉଞతͳঢ়ଶʹ͢Δ • ඇಉظϝοηʔδύογϯά • ػಈੑ͕͋Δ (Mobility) • ߋʹҎԼͷΑ͏ͳಛੑΛซͤ࣋ͭ • αʔϏεಉ࢜ڠௐͯ͠ಈ࡞͢Δ • ͦͷαʔϏε͚ͩͰ݁͢Δ
͋Γ͕ͱ͏͍͟͝·ͨ͠ʂ