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
Microservices architecture pitfalls
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Mateusz Gajewski
March 07, 2015
Programming
230
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Microservices architecture pitfalls
This is the talk about common pitfalls met while building scalable microservice architecture
Mateusz Gajewski
March 07, 2015
More Decks by Mateusz Gajewski
See All by Mateusz Gajewski
Modern java for decade-old problems
wendigo
0
170
3 kroki do tyłu, 2 lata w przód
wendigo
2
190
JDD - Dług techniczny
wendigo
2
1.3k
WJUG 2017: 4 lata rewolucji mikrousługowej w Allegro
wendigo
0
360
4 lata rewolucji mikrousługowej w Allegro
wendigo
2
820
Project Rubicon
wendigo
0
380
RxJava - Reactive extensions for the JVM
wendigo
1
340
Building distributed systems with OSS
wendigo
1
190
Scaling infrastructure beyond containers
wendigo
1
180
Other Decks in Programming
See All in Programming
LLM本来の能力を解き放つサンドボックス技術とAI民主化への適用
yukukotani
3
3k
Spring Security 実践 ─ GraphQL APIで実務に役立つ 認証・認可 を学ぶ
wagyu
0
160
Inside Stream API
skrb
1
650
Modding RubyKaigi for Myself
yui_knk
0
890
代数的データ型って何が嬉しいの? #frontend_phpcon_do
kajitack
8
3.2k
権限チェックの一貫性を型で守る TypeScript による多層防御
mnch
4
1.1k
Stage 3 Decorators でできること / できないこと / TSKaigi 2026
susisu
1
1.6k
キャリア迷子上等 ─ "ない道"は自分で作ればいい
16bitidol
3
1.7k
肥大化するレガシーコードに立ち向かうためのインターフェース分離と依存の逆転 / JJUG CCC 2026 Spring
hirokunimaeta
0
500
TypeScript+Orvalで実現する型安全かつ堅牢でスケーラブルなマルチチャネル通知基盤 / TSKaigi Night talks ~after conference~
d0riven
0
300
AIとRubyの静的型付け
ukin0k0
0
540
ユニットテストの先へ:テスト技法で要求・仕様を整理するJava開発実践 / Beyond_Unit_Testing_Practical_Java_Development_Techniques_for_Organizing_Requirements_and_Specifications
shimashima35
0
350
Featured
See All Featured
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
360
The SEO identity crisis: Don't let AI make you average
varn
0
480
Color Theory Basics | Prateek | Gurzu
gurzu
0
350
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
220
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
280
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
118
120k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Paper Plane
katiecoart
PRO
1
51k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.3k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
570
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
310
Transcript
Microservices architecture pitfalls WJUG meeting ◦ march 2015 Mateusz Gajewski
Solutions Architect @ Allegro Twitter: @wendigo
About me given: I started working in Allegro in 2009
(5 mln AO, 50 devs) when: Allegro reached 40 mln AO, 400 devs then: I am Solutions Architect 2
Agenda • Microservices, microservices, microservices! ;) • Some challenges &
pitfalls: • Architectural, • Operational, • Organisational 3
Let’s go back in time to year 2012 4
5
Back then we wanted • agile development, • scalability, •
resilience, • lower costs, • hybrid cloud. 6
Basically SOA + JVM was an answer! 7
But our system was too BIG & too complex to
do it with existing enterprise solutions 8
s/Enterprise/OSS/g Solutions ;) 9
we’ve started to do *buzzword* 10
And now, literally everyone is doing microservices!!?? 11
Microservices by Fowler 12 Lots of *buzzwords* http://martinfowler.com/articles/microservices.html
SOA ≈ microservices? 13
microservices architecture ≈ fine-grained SOA − enterprise (commercial) sh*t ≈
highly scalable, distributed system 14
Distributed systems • concurrency of components, • independent failure of
components, • lack of a global clock. 15
The Eight Fallacies of Distributed Computing 16 by Peter Deutsch
1991
#1: Network is reliable 17
#2: Latency is zero 18
#3: Bandwidth is infinite 19
#4: Network is secure 20
#5: Topology doesn’t change 21
#6: There is one administrator 22
#7: Transport cost is zero 23
#8: Network is homogeneous 24
distributed systems are hard → microservices are much harder ;)
25
What have we learnt? 26
Act I: architectural constraints 27
CAP is not just theorem it’s reality against us 28
bye, bye ACID semantics 29
Long live BASE guarantees! Basically Available, Soft state, Eventually consistent
30
distributed transactions add complexity 31
it’s far cheaper to do compensation 32
33 http://bravenewgeek.com/you-cannot-have-exactly-once-delivery/
you need idempotent APIs and events sinks 34
35 choreography > orchestration
So we’ve built Hermes a.k.a circulatory system 36
network can be congested! 37
REST+JSON on top of HTTP/1.1 is fine 38
REST+JSON on top of HTTP/2.0 with TLS is finer 39
we don’t rely on network anymore net splits in public
clouds happens everytime! 40
we adopted antifragile organization 41
42
powerful tandem 43 + Reactive programming Circuit breaker pattern
you need to support non- native old services, clients and
systems 44
45
conclusion: constant architecture improvement 46
47 Act II: operational troubles
creating new service should be instant! 48
49
automation with gradle & axions 50
51
so now we’ve got over 1800 repositories grouped under 250
projects 52
all with CI, code quality checks, security checks, integrated with
sonar & artefact repository 53
but what with services upgrades? 54
we’ve initially built our own service stack … and it
was ok - for a while 55
now we are extending spring-boot with so called andamio project
56
rapid deployments integrated with CI/CD environment and canary tests are
must-have 57
war files ▾ scp + puppet ▾ golden images ▾
docker (immutable images) ▾ 58
frequency of changes → automated monitoring, logging &
operational insights 59
graphite statsd cabot tessera kibana logstash zabbix newrelic selena pingdom
… 60
Monitoring As A Service + SLA Monitoring + 61
we need to build real-time anomaly detection soon 62
63 Act III: organizational shift
strategic DDD is good for splitting up monolith 64
but leave tactical DDD up to teams 65
huge polyglot hangover 66
acquiring distributed skills 67
you build it - you run it 68
coupling avoidance 69
please don’t audit me 70
distributed (micro) data curation 71
So after two years… 72
73
Final thoughts 74
75
76
77
Thanks! Any questions? Visit our blog: allegrotech.io Follow us on
twitter: @allegrotechblog Check our OSS projects: github.com/allegro And meetup group: meetup.com/allegrotech 78