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
2024年にチャレンジしたことを振り返るぞ
mitchan
0
130
Wantedly での Datadog 活用事例
bgpat
1
430
20241214_WACATE2024冬_テスト設計技法をチョット俯瞰してみよう
kzsuzuki
3
440
ずっと昔に Star をつけたはずの思い出せない GitHub リポジトリを見つけたい!
rokuosan
0
150
私なりのAIのご紹介 [2024年版]
qt_luigi
1
120
レンジャーシステムズ | 会社紹介(採用ピッチ)
rssytems
0
150
re:Invent 2024 Innovation Talks(NET201)で語られた大切なこと
shotashiratori
0
300
バクラクのドキュメント解析技術と実データにおける課題 / layerx-ccc-winter-2024
shimacos
2
1k
[Ruby] Develop a Morse Code Learning Gem & Beep from Strings
oguressive
1
150
プロダクト開発を加速させるためのQA文化の築き方 / How to build QA culture to accelerate product development
mii3king
1
260
サイボウズフロントエンドエキスパートチームについて / FrontendExpert Team
cybozuinsideout
PRO
5
38k
社外コミュニティで学び社内に活かす共に学ぶプロジェクトの実践/backlogworld2024
nishiuma
0
250
Featured
See All Featured
Being A Developer After 40
akosma
87
590k
[RailsConf 2023] Rails as a piece of cake
palkan
53
5k
Build The Right Thing And Hit Your Dates
maggiecrowley
33
2.4k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
Building Adaptive Systems
keathley
38
2.3k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
Writing Fast Ruby
sferik
628
61k
The Cost Of JavaScript in 2023
addyosmani
45
7k
Mobile First: as difficult as doing things right
swwweet
222
9k
How to Ace a Technical Interview
jacobian
276
23k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
8
1.2k
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
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) • ߋʹҎԼͷΑ͏ͳಛੑΛซͤ࣋ͭ • αʔϏεಉ࢜ڠௐͯ͠ಈ࡞͢Δ • ͦͷαʔϏε͚ͩͰ݁͢Δ
͋Γ͕ͱ͏͍͟͝·ͨ͠ʂ