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
How Netflix does Failovers in 7 minutes
Search
Amjith
May 12, 2018
Programming
0
560
How Netflix does Failovers in 7 minutes
Amjith
May 12, 2018
Tweet
Share
More Decks by Amjith
See All by Amjith
Awesome Commandline Tools
amjith
0
450
FuzzyFind
amjith
0
71
Awesome Command Line Tools
amjith
1
130
Modern Command Line
amjith
2
290
Introduction to Docker
amjith
8
1.4k
Thread Profiling in Python
amjith
7
830
Python Profiling
amjith
3
310
Statistical Thread Profiler
amjith
1
130
Debugging Live Python Web Applications
amjith
8
1.6k
Other Decks in Programming
See All in Programming
Node.js v22 で変わること
yosuke_furukawa
PRO
11
3.9k
R言語の環境構築と基礎 Tokyo.R 112
bob3bob3
0
280
try! Swift Tokyo 2024 参加報告 / try! Swift Tokyo 2024 Report
hironytic
0
220
初心者のためのRubyKaigi入門/RubyKaigi Introduction
a_matsuda
8
1.4k
敵対的ポイフル
futabato
0
120
検証も兼ねて個人開発でHonoとかと向き合った話
hanetsuki
1
1.3k
StoreKit2によるiOSのアプリ内課金のリニューアル
kangnux
0
120
はてなにおける CSS Modules、及び CSS Modules に足りないもの / CSS Modules in Hatena, and CSS Modules missing parts
mizdra
7
970
Ruby Pattern Matching
bkuhlmann
0
930
ゆるい個人開発のススメ
kuroppe1819
10
1k
From Spring Boot 2 to Spring Boot 3 with Java 21 and Jakarta EE
ivargrimstad
0
430
Snowflakeで眠ったデータを起こそう!
estie
0
140
Featured
See All Featured
Fireside Chat
paigeccino
22
2.6k
Ruby is Unlike a Banana
tanoku
96
10k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
11
1k
We Have a Design System, Now What?
morganepeng
44
6.8k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
660
120k
YesSQL, Process and Tooling at Scale
rocio
165
13k
The Brand Is Dead. Long Live the Brand.
mthomps
49
29k
What's in a price? How to price your products and services
michaelherold
238
11k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
79
43k
The Pragmatic Product Professional
lauravandoore
26
5.8k
Typedesign – Prime Four
hannesfritz
36
2.1k
5 minutes of I Can Smell Your CMS
philhawksworth
199
19k
Transcript
None
None
Whoops, something went wrong… Netflix Streaming Error We’re having trouble
playing this title right now. Please try again later or select a different title.
None
None
Cloud Prod Engineering AMJITH RAMANUJAM (@amjithr) Sr. Software Engineer, Traffic
Team
Regional Failover in 7 minutes AMJITH RAMANUJAM (@amjithr) Sr. Software
Engineer, Traffic Team
Regional Standby system takes over when the main system fails
Failover
None
Amazon Web Services Everything else Netflix Open Connect All video
delivery
Regional Failover
Christmas Eve 2012
None
None
None
None
ELB Outage 7 Hours
16,000 years in 1 day content watched ~14,000 BC: First
colonization of America 2018 0 AD 4,600 years in 7 hours
Regional Failover
Active - standby system is also serving traffic Active vs
Passive Passive - standby system is NOT serving traffic
Stateless services Prerequisites Regional replication of data
Infrastructure problem isolated to one region Failover Candidate Problem won’t
follow if we move traffic Bad code deploy in a region
Detect the problem Regional Failover Process Scale the savior regions
Shift traffic
None
Detect the problem
Is it working?
None
One metric to rule them all - Dumbledore
SPS Stream Starts Per Second
None
Scale Saviors
None
None
None
Scaling Pattern Linear Regression
Shift Traffic
Proxy Traffic Traffic Shift Switch DNS
None
Detect the problem - 5 minutes Regional Failover Process Scale
the savior regions - 35 minutes Shift traffic - 10 minutes Total = 45 mins
Nimble Goals • Fast failover (<10mins) ◦ Pre-scale • Transparent
to service owners ◦ No code changes for service owners ◦ No auto-scaling changes
API lolomo nccp Playready us-west
API lolomo nccp nimble_API nimble_lolomo nimble_nccp Playready nimble_Playready us-west
API lolomo nccp nimble_API nimble_lolomo nimble_nccp Playready nimble_Playready us-west
API lolomo nccp nimble_API nimble_lolomo nimble_nccp starting starting starting starting
Playready nimble_Playready us-west
Failover API lolomo nccp Playready nimble_API nimble_Playready nimble_lolomo nimble_nccp
Failover API lolomo nccp Playready nimble_API nimble_Playready nimble_lolomo nimble_nccp
Failover API lolomo nccp Playready nimble_API nimble_Playready nimble_lolomo nimble_nccp
Failover API lolomo nccp nimble_API nimble_lolomo nimble_nccp Playready nimble_Playready
Detect the problem - 2 minutes Regional Failover Process Scale
the savior regions - 4 minutes Shift traffic - 3 minutes Total = 7 mins
Architecture
Actions Periodic Tasks Triggered Tasks
Periodic Tasks Fetch historical data Predict cluster sizes Manage dark
clusters
Triggered Tasks Ungate dark instances Transplant instances Traffic shift
Nanoservices Python Flask RQ - Redis
Characteristics Anticipate Failure Eventually Consistent Garbage Collect
Anticipate Failure Multi-region Rebuild state from scratch Fallbacks
Fallbacks AWS State - EDDA Historical data - ATLAS Local
Cache - Redis, Filesystem
Eventual Consistency AWS is eventually consistent Favor idempotent actions
Orphan Cleaner • Terminate detached instances • Safety features ◦
Terminate slowly ◦ Don’t terminate large volume of instances
FAQs How often do you failover? Why not have dark
clusters take traffic? How much did Nimble cost?
Suggestions Fallbacks, Fallbacks, Fallbacks Exercise it often Provide visibility
We’re hiring! @amjithr