SlideShare a Scribd company logo
1 of 83
Justin Ryan, Senior Software Engineer @ Netflix
Twitter: quidryan, LinkedIn: www.linkedin.com/in/justin-charles-ryan
Scaling
Patterns for
Netflix’s Edge
November 2019
InfoQ.com: News & Community Site
• Over 1,000,000 software developers, architects and CTOs read the site world-
wide every month
• 250,000 senior developers subscribe to our weekly newsletter
• Published in 4 languages (English, Chinese, Japanese and Brazilian
Portuguese)
• Post content from our QCon conferences
• 2 dedicated podcast channels: The InfoQ Podcast, with a focus on
Architecture and The Engineering Culture Podcast, with a focus on building
• 96 deep dives on innovative topics packed as downloadable emags and
minibooks
• Over 40 new content items per week
Watch the video with slide
synchronization on InfoQ.com!
https://www.infoq.com/presentations/
netflix-edge-scalability-patterns/
Purpose of QCon
- to empower software development by facilitating the spread of
knowledge and innovation
Strategy
- practitioner-driven conference designed for YOU: influencers of
change and innovation in your teams
- speakers and topics driving the evolution and innovation
- connecting and catalyzing the influencers and innovators
Highlights
- attended by more than 12,000 delegates since 2007
- held in 9 cities worldwide
Presented at QCon San Francisco
www.qconsf.com
Scaling Patterns for Netflix’s Edge
Justin Ryan
Laundry
Scaling Patterns for Netflix’s Edge
Justin Ryan
Laundry
Scaling Patterns for Netflix’s Edge
Justin Ryan
Laundry
Scaling Patterns for Netflix’s Edge
Justin Ryan
Laundry
Scaling Patterns for Netflix’s Edge
Justin Ryan
Space-Time Compromise
Scaling Patterns for Netflix’s Edge
Justin Ryan
Laundry
Scaling Patterns for Netflix’s Edge
Justin Ryan
Scaling
Q32011
Q32019
Scaling Patterns for Netflix’s Edge
Justin Ryan
Scaling
Edge
Scaling Patterns for Netflix’s Edge
Justin Ryan
Scaling
Problems
— Debuggability
— Infrastructure
— Managing
Scaling Patterns for Netflix’s Edge
Justin Ryan
Scalability
Scaling Patterns for Netflix’s Edge
Justin Ryan
Trade Offs
Scaling Patterns for Netflix’s Edge
Justin Ryan
Policies
Scaling Patterns for Netflix’s Edge
Justin Ryan
Accessible
Scaling Patterns for Netflix’s Edge
Justin Ryan
Five Use
Cases
— Melnitz
— Mantis
— Passport
— Device Types
— Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
Logged In
Scaling Patterns for Netflix’s Edge
Justin Ryan
Cookies
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Trust Cookie Cookie Expiration
Scaling Patterns for Netflix’s Edge
Justin Ryan
Cookies
L7 Proxy
Account
Service
API
Expired
Yes
No
Scaling Patterns for Netflix’s Edge
Justin Ryan
Boom
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Copyright Columbia Pictures
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Set<CustomerId> Cookie Expiration
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz Bloom Filter: Compact Set which
can answer the question is an object
“Possibly in Set”?
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Scaling Patterns for Netflix’s Edge
Justin Ryan
Side Note:
Bloom Filter
— Bad Interview Question? Yes
— Used in complex databases? Yes
— Guava Library? Yes
— Usable by you in your day-to-day
jobs? Yes
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
L7 Proxy
Account
Service
API
Bloom
Filter
Expired
Yes
No
Maybe
No
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Account
Service Auth
Event
Melnitz A
DB
Melnitz B
1m
L7 Proxy
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Scaling Patterns for Netflix’s Edge
Justin Ryan
Melnitz
Trade Offs
— Probabilistic Data Structure
— Off the Shelf Components
Scaling Patterns for Netflix’s Edge
Justin Ryan
Side Note: Bloom Filter
Scaling Patterns for Netflix’s Edge
Justin Ryan
Five Use
Cases
— Melnitz - Distributed Bloom Filter
— Mantis
— Passport
— Device Types
— Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis 2 million request per second *
3 kilobytes per request *
10 micro-services =
57 GB/s =~ 4.6 PB / day
Scaling Patterns for Netflix’s Edge
Justin Ryan
Naive Approach
Service Elastic Search
Kibana
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis Master
Mantis
Service
Mantis
Agent
Mantis
Source
Job
Elastic Search
Kibana
Kafka
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis Master
Service
Mantis
Mantis
Source
Job
Elastic Search
Browser
Mantis
Agent
Kafka
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis Master
Mantis
Service
Mantis
Agent
Mantis
Source
Job
Elastic Search
Browser
Metrics
Javascript
Transform
Scaling Patterns for Netflix’s Edge
Justin Ryan
Avoid Work
Scaling Patterns for Netflix’s Edge
Justin Ryan
Mantis
Trade Offs
— Mantis Query Language
— Scale Solution to Zero
Scaling Patterns for Netflix’s Edge
Justin Ryan
Five Use
Cases
— Melnitz - Distributed Bloom Filter
— Mantis - Event Querying
— Passport
— Device Types
— Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
Passport
Scaling Patterns for Netflix’s Edge
Justin Ryan
Service
Plan
API
L7Proxy
Mid Tier A
Mid Tier B
Mid Tier C
Passport
Scaling Patterns for Netflix’s Edge
Justin Ryan
Passport
Service
Plan
API
L7Proxy
Mid Tier A
Mid Tier B
Mid Tier C
Scaling Patterns for Netflix’s Edge
Justin Ryan
Cache
Service
Plan
API
L7Proxy
Mid Tier A
Mid Tier B
Mid Tier C
Scaling Patterns for Netflix’s Edge
Justin Ryan
Cache
API
L7Proxy
Mid Tier A
Mid Tier B
Mid Tier C
Service
Plan
Scaling Patterns for Netflix’s Edge
Justin Ryan
Cache
API
L7Proxy
Mid Tier A
Mid Tier B
Mid Tier C
Service
Plan
Scaling Patterns for Netflix’s Edge
Justin Ryan
Passport
Scaling Patterns for Netflix’s Edge
Justin Ryan
Passport
Trade Offs
— Data Passing
— Heavy Data Structures
Scaling Patterns for Netflix’s Edge
Justin Ryan
Five Use
Cases
— Melnitz - Distributed Bloom Filter
— Mantis - Event Querying
— Passport - Heavy Data Structure
— Device Types
— Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
NFAPPL-01-IPAD7=5-09BEC57F64CA5F837C75F924B94D
NFAPPL-01-IPAD3=4-15B2D9B33A994CC373017A9C6586
NFAPPL-02-IOS2=4-FT7WHG8H2UR2MCJ4YKR3P0DFH6
NFANDROID1-PRV-P-GOOGLPIXEL=2-7351-0F441DF98B8D99074
NFANDROID1-PRV-4339-0E50FC7582396F5C4496ED935F2F48ED
1395
1007
964
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Mid-Tier F
Mid-Tier E Mid-Tier D
Mid-Tier C
Mid-Tier BMid-Tier A
DTS
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Mid-Tier CMid-Tier BMid-Tier A
DTS PubSub
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Mid-Tier CMid-Tier BMid-Tier A
DTS PubSub
Device Types Device TypesDevice Types
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Types
Scaling Patterns for Netflix’s Edge
Justin Ryan
Device Type
Trade Offs
— Business Tuned Fallbacks
— Leverage Existing Infrastructure
Scaling Patterns for Netflix’s Edge
Justin Ryan
Five Use
Cases
— Melnitz - Distributed Bloom Filter
— Mantis - Event Querying
— Passport - Heavy Data Structure
— Device Types - Device Grouping
— Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
MSL — Message Security Layer == MSL
— Secure Messaging Framework
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding MSL
L7Proxy
APIAPIAPIAPIAPIAPI
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding MSL
L7Proxy
MSL
APIAPIAPI
Scaling Patterns for Netflix’s Edge
Justin Ryan
CPU Cost Per Request
- CPU to RPS ratio
- Load Average
31%
decrease
Scaling Patterns for Netflix’s Edge
Justin Ryan
Latency
30%
decrease
20% p99
decrease
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding MSL
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding MSL
- % of Wall Clock in GC
- GC Pause Time
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding MSL
- Average Latency
- 99% Latency
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding
3 = 1 + 1
Scaling Patterns for Netflix’s Edge
Justin Ryan
Sharding
Trade Offs
— Operational Overhead
Scaling Patterns for Netflix’s Edge
Justin Ryan
Five Use
Cases
— Melnitz - Distributed Bloom Filter
— Mantis - Event Querying
— Passport - Heavy Data Structure
— Device Types - Device Grouping
— Sharding - Runtime Refactoring
Scaling Patterns for Netflix’s Edge
Justin Ryan
Trough
Scaling Patterns for Netflix’s Edge
Justin Ryan
Trough - Used Instances
- Reserved Instances
Scaling Patterns for Netflix’s Edge
Justin Ryan
Pattern #6
Trough
— Leverage Unused Resources
Scaling Patterns for Netflix’s Edge
Justin Ryan
Trade Odds
● Probabilistic Data Structure
● Off the Shelf Components
● Avoid Work
● Scale Solution to Zero
● Data Passing
● Heavy Data Structures
● Leverage Existing Infrastructure
● Business Tuned Fallbacks
● Runtime Refactoring
Melnitz
Melnitz
Mantis
Mantis
Passport
Passport
DTS
DTS
Sharding
Scaling Patterns for Netflix’s Edge
Justin Ryan
When to Use
Debuggability ✗ ✓ ✓ ✓ ✓ ✗
Infrastructure ✓ ✗ ✗ ✓ ✗ ✗
Managing ✗ ✗ ✗ ✓ ✗ ✗
Costs ✓ ✓ ✗ ✗ ✓ ✓
Melnitz
Mantis
Passport
DeviceTypesSharding
Trough
Scaling Patterns for Netflix’s Edge
Justin Ryan
Bonus Trade
Offs
— Do the laundry
Justin Ryan
jryan@netflix.com
Twitter: @quidryan
Thank
You.
Scaling Patterns for Netflix’s Edge
Justin Ryan
References — github.com/Netflix
◆ eureka
◆ zuul
◆ mantis
◆ msl
— Spinnaker
— Apache Pulsar
— Google Guava (Bloom Filter)
Watch the video with slide
synchronization on InfoQ.com!
https://www.infoq.com/presentations/
netflix-edge-scalability-patterns/

More Related Content

Similar to Scaling Patterns for Netflix's Edge

Cilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPFCilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPFCynthia Thomas
 
TIBCO Advanced Analytics Meetup (TAAM) - June 2015
TIBCO Advanced Analytics Meetup (TAAM) - June 2015TIBCO Advanced Analytics Meetup (TAAM) - June 2015
TIBCO Advanced Analytics Meetup (TAAM) - June 2015Bipin Singh
 
Scaling the Netflix API - From Atlassian Dev Den
Scaling the Netflix API - From Atlassian Dev DenScaling the Netflix API - From Atlassian Dev Den
Scaling the Netflix API - From Atlassian Dev DenDaniel Jacobson
 
Netflix: From Zero to Production-Ready in Minutes (QCon 2017)
Netflix: From Zero to Production-Ready in Minutes (QCon 2017)Netflix: From Zero to Production-Ready in Minutes (QCon 2017)
Netflix: From Zero to Production-Ready in Minutes (QCon 2017)Tim Bozarth
 
Cyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per Day
Cyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per DayCyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per Day
Cyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per DayAmazon Web Services
 
Oscon2014 Netflix API - Top 10 Lessons Learned
Oscon2014 Netflix API - Top 10 Lessons LearnedOscon2014 Netflix API - Top 10 Lessons Learned
Oscon2014 Netflix API - Top 10 Lessons LearnedSangeeta Narayanan
 
Customer Experience at Disney+ Through Data Perspective
Customer Experience at Disney+ Through Data PerspectiveCustomer Experience at Disney+ Through Data Perspective
Customer Experience at Disney+ Through Data PerspectiveDatabricks
 
Customer experience at disney+ through data perspective
Customer experience at disney+ through data perspectiveCustomer experience at disney+ through data perspective
Customer experience at disney+ through data perspectiveMartin Zapletal
 
Programming with Semantic Broad Data
Programming with Semantic Broad DataProgramming with Semantic Broad Data
Programming with Semantic Broad DataSteffen Staab
 
Standardize Database Development Across your Organization in 4 Key Steps
Standardize Database Development Across your Organization in 4 Key StepsStandardize Database Development Across your Organization in 4 Key Steps
Standardize Database Development Across your Organization in 4 Key StepsRed Gate Software
 
Microservice Scars - Alt.net 2hr
Microservice Scars - Alt.net 2hrMicroservice Scars - Alt.net 2hr
Microservice Scars - Alt.net 2hrJoshua Toth
 
Evolution of the Netflix API
Evolution of the Netflix APIEvolution of the Netflix API
Evolution of the Netflix APIC4Media
 
RIPE NCC Operations and Analysis Tools
RIPE NCC Operations and Analysis ToolsRIPE NCC Operations and Analysis Tools
RIPE NCC Operations and Analysis ToolsRIPE NCC
 
Microservices, Events, and Breaking the Data Monolith with Kafka
Microservices, Events, and Breaking the Data Monolith with KafkaMicroservices, Events, and Breaking the Data Monolith with Kafka
Microservices, Events, and Breaking the Data Monolith with KafkaVMware Tanzu
 
Fast Delivery DevOps Israel
Fast Delivery DevOps IsraelFast Delivery DevOps Israel
Fast Delivery DevOps IsraelAdrian Cockcroft
 
Maintaining the Front Door to Netflix : The Netflix API
Maintaining the Front Door to Netflix : The Netflix APIMaintaining the Front Door to Netflix : The Netflix API
Maintaining the Front Door to Netflix : The Netflix APIDaniel Jacobson
 
Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018
Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018
Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018Amazon Web Services
 
Top 10 Lessons Learned from the Netflix API - OSCON 2014
Top 10 Lessons Learned from the Netflix API - OSCON 2014Top 10 Lessons Learned from the Netflix API - OSCON 2014
Top 10 Lessons Learned from the Netflix API - OSCON 2014Daniel Jacobson
 

Similar to Scaling Patterns for Netflix's Edge (20)

Cilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPFCilium:: Application-Aware Microservices via BPF
Cilium:: Application-Aware Microservices via BPF
 
TIBCO Advanced Analytics Meetup (TAAM) - June 2015
TIBCO Advanced Analytics Meetup (TAAM) - June 2015TIBCO Advanced Analytics Meetup (TAAM) - June 2015
TIBCO Advanced Analytics Meetup (TAAM) - June 2015
 
Scaling the Netflix API - From Atlassian Dev Den
Scaling the Netflix API - From Atlassian Dev DenScaling the Netflix API - From Atlassian Dev Den
Scaling the Netflix API - From Atlassian Dev Den
 
Netflix: From Zero to Production-Ready in Minutes (QCon 2017)
Netflix: From Zero to Production-Ready in Minutes (QCon 2017)Netflix: From Zero to Production-Ready in Minutes (QCon 2017)
Netflix: From Zero to Production-Ready in Minutes (QCon 2017)
 
Cyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per Day
Cyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per DayCyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per Day
Cyber Data Lake: How CIS Analyzes Billions of Network Traffic Records per Day
 
Oscon2014 Netflix API - Top 10 Lessons Learned
Oscon2014 Netflix API - Top 10 Lessons LearnedOscon2014 Netflix API - Top 10 Lessons Learned
Oscon2014 Netflix API - Top 10 Lessons Learned
 
Mesoscon 2015
Mesoscon 2015Mesoscon 2015
Mesoscon 2015
 
Customer Experience at Disney+ Through Data Perspective
Customer Experience at Disney+ Through Data PerspectiveCustomer Experience at Disney+ Through Data Perspective
Customer Experience at Disney+ Through Data Perspective
 
Customer experience at disney+ through data perspective
Customer experience at disney+ through data perspectiveCustomer experience at disney+ through data perspective
Customer experience at disney+ through data perspective
 
Programming with Semantic Broad Data
Programming with Semantic Broad DataProgramming with Semantic Broad Data
Programming with Semantic Broad Data
 
Standardize Database Development Across your Organization in 4 Key Steps
Standardize Database Development Across your Organization in 4 Key StepsStandardize Database Development Across your Organization in 4 Key Steps
Standardize Database Development Across your Organization in 4 Key Steps
 
Microservice Scars - Alt.net 2hr
Microservice Scars - Alt.net 2hrMicroservice Scars - Alt.net 2hr
Microservice Scars - Alt.net 2hr
 
Evolution of the Netflix API
Evolution of the Netflix APIEvolution of the Netflix API
Evolution of the Netflix API
 
RIPE NCC Operations and Analysis Tools
RIPE NCC Operations and Analysis ToolsRIPE NCC Operations and Analysis Tools
RIPE NCC Operations and Analysis Tools
 
Microservices, Events, and Breaking the Data Monolith with Kafka
Microservices, Events, and Breaking the Data Monolith with KafkaMicroservices, Events, and Breaking the Data Monolith with Kafka
Microservices, Events, and Breaking the Data Monolith with Kafka
 
Fast Delivery DevOps Israel
Fast Delivery DevOps IsraelFast Delivery DevOps Israel
Fast Delivery DevOps Israel
 
Netflix MSA and Pivotal
Netflix MSA and PivotalNetflix MSA and Pivotal
Netflix MSA and Pivotal
 
Maintaining the Front Door to Netflix : The Netflix API
Maintaining the Front Door to Netflix : The Netflix APIMaintaining the Front Door to Netflix : The Netflix API
Maintaining the Front Door to Netflix : The Netflix API
 
Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018
Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018
Real-World Use Cases for Amazon DynamoDB (DAT333) - AWS re:Invent 2018
 
Top 10 Lessons Learned from the Netflix API - OSCON 2014
Top 10 Lessons Learned from the Netflix API - OSCON 2014Top 10 Lessons Learned from the Netflix API - OSCON 2014
Top 10 Lessons Learned from the Netflix API - OSCON 2014
 

More from C4Media

Streaming a Million Likes/Second: Real-Time Interactions on Live Video
Streaming a Million Likes/Second: Real-Time Interactions on Live VideoStreaming a Million Likes/Second: Real-Time Interactions on Live Video
Streaming a Million Likes/Second: Real-Time Interactions on Live VideoC4Media
 
Next Generation Client APIs in Envoy Mobile
Next Generation Client APIs in Envoy MobileNext Generation Client APIs in Envoy Mobile
Next Generation Client APIs in Envoy MobileC4Media
 
Software Teams and Teamwork Trends Report Q1 2020
Software Teams and Teamwork Trends Report Q1 2020Software Teams and Teamwork Trends Report Q1 2020
Software Teams and Teamwork Trends Report Q1 2020C4Media
 
Understand the Trade-offs Using Compilers for Java Applications
Understand the Trade-offs Using Compilers for Java ApplicationsUnderstand the Trade-offs Using Compilers for Java Applications
Understand the Trade-offs Using Compilers for Java ApplicationsC4Media
 
Kafka Needs No Keeper
Kafka Needs No KeeperKafka Needs No Keeper
Kafka Needs No KeeperC4Media
 
High Performing Teams Act Like Owners
High Performing Teams Act Like OwnersHigh Performing Teams Act Like Owners
High Performing Teams Act Like OwnersC4Media
 
Does Java Need Inline Types? What Project Valhalla Can Bring to Java
Does Java Need Inline Types? What Project Valhalla Can Bring to JavaDoes Java Need Inline Types? What Project Valhalla Can Bring to Java
Does Java Need Inline Types? What Project Valhalla Can Bring to JavaC4Media
 
Service Meshes- The Ultimate Guide
Service Meshes- The Ultimate GuideService Meshes- The Ultimate Guide
Service Meshes- The Ultimate GuideC4Media
 
Shifting Left with Cloud Native CI/CD
Shifting Left with Cloud Native CI/CDShifting Left with Cloud Native CI/CD
Shifting Left with Cloud Native CI/CDC4Media
 
CI/CD for Machine Learning
CI/CD for Machine LearningCI/CD for Machine Learning
CI/CD for Machine LearningC4Media
 
Fault Tolerance at Speed
Fault Tolerance at SpeedFault Tolerance at Speed
Fault Tolerance at SpeedC4Media
 
Architectures That Scale Deep - Regaining Control in Deep Systems
Architectures That Scale Deep - Regaining Control in Deep SystemsArchitectures That Scale Deep - Regaining Control in Deep Systems
Architectures That Scale Deep - Regaining Control in Deep SystemsC4Media
 
ML in the Browser: Interactive Experiences with Tensorflow.js
ML in the Browser: Interactive Experiences with Tensorflow.jsML in the Browser: Interactive Experiences with Tensorflow.js
ML in the Browser: Interactive Experiences with Tensorflow.jsC4Media
 
Build Your Own WebAssembly Compiler
Build Your Own WebAssembly CompilerBuild Your Own WebAssembly Compiler
Build Your Own WebAssembly CompilerC4Media
 
User & Device Identity for Microservices @ Netflix Scale
User & Device Identity for Microservices @ Netflix ScaleUser & Device Identity for Microservices @ Netflix Scale
User & Device Identity for Microservices @ Netflix ScaleC4Media
 
Make Your Electron App Feel at Home Everywhere
Make Your Electron App Feel at Home EverywhereMake Your Electron App Feel at Home Everywhere
Make Your Electron App Feel at Home EverywhereC4Media
 
The Talk You've Been Await-ing For
The Talk You've Been Await-ing ForThe Talk You've Been Await-ing For
The Talk You've Been Await-ing ForC4Media
 
Future of Data Engineering
Future of Data EngineeringFuture of Data Engineering
Future of Data EngineeringC4Media
 
Automated Testing for Terraform, Docker, Packer, Kubernetes, and More
Automated Testing for Terraform, Docker, Packer, Kubernetes, and MoreAutomated Testing for Terraform, Docker, Packer, Kubernetes, and More
Automated Testing for Terraform, Docker, Packer, Kubernetes, and MoreC4Media
 
Navigating Complexity: High-performance Delivery and Discovery Teams
Navigating Complexity: High-performance Delivery and Discovery TeamsNavigating Complexity: High-performance Delivery and Discovery Teams
Navigating Complexity: High-performance Delivery and Discovery TeamsC4Media
 

More from C4Media (20)

Streaming a Million Likes/Second: Real-Time Interactions on Live Video
Streaming a Million Likes/Second: Real-Time Interactions on Live VideoStreaming a Million Likes/Second: Real-Time Interactions on Live Video
Streaming a Million Likes/Second: Real-Time Interactions on Live Video
 
Next Generation Client APIs in Envoy Mobile
Next Generation Client APIs in Envoy MobileNext Generation Client APIs in Envoy Mobile
Next Generation Client APIs in Envoy Mobile
 
Software Teams and Teamwork Trends Report Q1 2020
Software Teams and Teamwork Trends Report Q1 2020Software Teams and Teamwork Trends Report Q1 2020
Software Teams and Teamwork Trends Report Q1 2020
 
Understand the Trade-offs Using Compilers for Java Applications
Understand the Trade-offs Using Compilers for Java ApplicationsUnderstand the Trade-offs Using Compilers for Java Applications
Understand the Trade-offs Using Compilers for Java Applications
 
Kafka Needs No Keeper
Kafka Needs No KeeperKafka Needs No Keeper
Kafka Needs No Keeper
 
High Performing Teams Act Like Owners
High Performing Teams Act Like OwnersHigh Performing Teams Act Like Owners
High Performing Teams Act Like Owners
 
Does Java Need Inline Types? What Project Valhalla Can Bring to Java
Does Java Need Inline Types? What Project Valhalla Can Bring to JavaDoes Java Need Inline Types? What Project Valhalla Can Bring to Java
Does Java Need Inline Types? What Project Valhalla Can Bring to Java
 
Service Meshes- The Ultimate Guide
Service Meshes- The Ultimate GuideService Meshes- The Ultimate Guide
Service Meshes- The Ultimate Guide
 
Shifting Left with Cloud Native CI/CD
Shifting Left with Cloud Native CI/CDShifting Left with Cloud Native CI/CD
Shifting Left with Cloud Native CI/CD
 
CI/CD for Machine Learning
CI/CD for Machine LearningCI/CD for Machine Learning
CI/CD for Machine Learning
 
Fault Tolerance at Speed
Fault Tolerance at SpeedFault Tolerance at Speed
Fault Tolerance at Speed
 
Architectures That Scale Deep - Regaining Control in Deep Systems
Architectures That Scale Deep - Regaining Control in Deep SystemsArchitectures That Scale Deep - Regaining Control in Deep Systems
Architectures That Scale Deep - Regaining Control in Deep Systems
 
ML in the Browser: Interactive Experiences with Tensorflow.js
ML in the Browser: Interactive Experiences with Tensorflow.jsML in the Browser: Interactive Experiences with Tensorflow.js
ML in the Browser: Interactive Experiences with Tensorflow.js
 
Build Your Own WebAssembly Compiler
Build Your Own WebAssembly CompilerBuild Your Own WebAssembly Compiler
Build Your Own WebAssembly Compiler
 
User & Device Identity for Microservices @ Netflix Scale
User & Device Identity for Microservices @ Netflix ScaleUser & Device Identity for Microservices @ Netflix Scale
User & Device Identity for Microservices @ Netflix Scale
 
Make Your Electron App Feel at Home Everywhere
Make Your Electron App Feel at Home EverywhereMake Your Electron App Feel at Home Everywhere
Make Your Electron App Feel at Home Everywhere
 
The Talk You've Been Await-ing For
The Talk You've Been Await-ing ForThe Talk You've Been Await-ing For
The Talk You've Been Await-ing For
 
Future of Data Engineering
Future of Data EngineeringFuture of Data Engineering
Future of Data Engineering
 
Automated Testing for Terraform, Docker, Packer, Kubernetes, and More
Automated Testing for Terraform, Docker, Packer, Kubernetes, and MoreAutomated Testing for Terraform, Docker, Packer, Kubernetes, and More
Automated Testing for Terraform, Docker, Packer, Kubernetes, and More
 
Navigating Complexity: High-performance Delivery and Discovery Teams
Navigating Complexity: High-performance Delivery and Discovery TeamsNavigating Complexity: High-performance Delivery and Discovery Teams
Navigating Complexity: High-performance Delivery and Discovery Teams
 

Recently uploaded

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 

Recently uploaded (20)

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 

Scaling Patterns for Netflix's Edge

  • 1. Justin Ryan, Senior Software Engineer @ Netflix Twitter: quidryan, LinkedIn: www.linkedin.com/in/justin-charles-ryan Scaling Patterns for Netflix’s Edge November 2019
  • 2. InfoQ.com: News & Community Site • Over 1,000,000 software developers, architects and CTOs read the site world- wide every month • 250,000 senior developers subscribe to our weekly newsletter • Published in 4 languages (English, Chinese, Japanese and Brazilian Portuguese) • Post content from our QCon conferences • 2 dedicated podcast channels: The InfoQ Podcast, with a focus on Architecture and The Engineering Culture Podcast, with a focus on building • 96 deep dives on innovative topics packed as downloadable emags and minibooks • Over 40 new content items per week Watch the video with slide synchronization on InfoQ.com! https://www.infoq.com/presentations/ netflix-edge-scalability-patterns/
  • 3. Purpose of QCon - to empower software development by facilitating the spread of knowledge and innovation Strategy - practitioner-driven conference designed for YOU: influencers of change and innovation in your teams - speakers and topics driving the evolution and innovation - connecting and catalyzing the influencers and innovators Highlights - attended by more than 12,000 delegates since 2007 - held in 9 cities worldwide Presented at QCon San Francisco www.qconsf.com
  • 4. Scaling Patterns for Netflix’s Edge Justin Ryan Laundry
  • 5. Scaling Patterns for Netflix’s Edge Justin Ryan Laundry
  • 6. Scaling Patterns for Netflix’s Edge Justin Ryan Laundry
  • 7. Scaling Patterns for Netflix’s Edge Justin Ryan Laundry
  • 8. Scaling Patterns for Netflix’s Edge Justin Ryan Space-Time Compromise
  • 9. Scaling Patterns for Netflix’s Edge Justin Ryan Laundry
  • 10. Scaling Patterns for Netflix’s Edge Justin Ryan Scaling Q32011 Q32019
  • 11. Scaling Patterns for Netflix’s Edge Justin Ryan Scaling Edge
  • 12. Scaling Patterns for Netflix’s Edge Justin Ryan Scaling Problems — Debuggability — Infrastructure — Managing
  • 13. Scaling Patterns for Netflix’s Edge Justin Ryan Scalability
  • 14. Scaling Patterns for Netflix’s Edge Justin Ryan Trade Offs
  • 15. Scaling Patterns for Netflix’s Edge Justin Ryan Policies
  • 16. Scaling Patterns for Netflix’s Edge Justin Ryan Accessible
  • 17. Scaling Patterns for Netflix’s Edge Justin Ryan Five Use Cases — Melnitz — Mantis — Passport — Device Types — Sharding
  • 18. Scaling Patterns for Netflix’s Edge Justin Ryan Logged In
  • 19. Scaling Patterns for Netflix’s Edge Justin Ryan Cookies
  • 20. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz Trust Cookie Cookie Expiration
  • 21. Scaling Patterns for Netflix’s Edge Justin Ryan Cookies L7 Proxy Account Service API Expired Yes No
  • 22. Scaling Patterns for Netflix’s Edge Justin Ryan Boom
  • 23. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz Copyright Columbia Pictures
  • 24. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz Set<CustomerId> Cookie Expiration
  • 25. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz Bloom Filter: Compact Set which can answer the question is an object “Possibly in Set”?
  • 26. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz
  • 27. Scaling Patterns for Netflix’s Edge Justin Ryan Side Note: Bloom Filter — Bad Interview Question? Yes — Used in complex databases? Yes — Guava Library? Yes — Usable by you in your day-to-day jobs? Yes
  • 28. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz L7 Proxy Account Service API Bloom Filter Expired Yes No Maybe No
  • 29. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz Account Service Auth Event Melnitz A DB Melnitz B 1m L7 Proxy
  • 30. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz
  • 31. Scaling Patterns for Netflix’s Edge Justin Ryan Melnitz Trade Offs — Probabilistic Data Structure — Off the Shelf Components
  • 32. Scaling Patterns for Netflix’s Edge Justin Ryan Side Note: Bloom Filter
  • 33. Scaling Patterns for Netflix’s Edge Justin Ryan Five Use Cases — Melnitz - Distributed Bloom Filter — Mantis — Passport — Device Types — Sharding
  • 34. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis
  • 35. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis 2 million request per second * 3 kilobytes per request * 10 micro-services = 57 GB/s =~ 4.6 PB / day
  • 36. Scaling Patterns for Netflix’s Edge Justin Ryan Naive Approach Service Elastic Search Kibana
  • 37. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis
  • 38. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis Master Mantis Service Mantis Agent Mantis Source Job Elastic Search Kibana Kafka
  • 39. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis Master Service Mantis Mantis Source Job Elastic Search Browser Mantis Agent Kafka
  • 40. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis Master Mantis Service Mantis Agent Mantis Source Job Elastic Search Browser Metrics Javascript Transform
  • 41. Scaling Patterns for Netflix’s Edge Justin Ryan Avoid Work
  • 42. Scaling Patterns for Netflix’s Edge Justin Ryan Mantis Trade Offs — Mantis Query Language — Scale Solution to Zero
  • 43. Scaling Patterns for Netflix’s Edge Justin Ryan Five Use Cases — Melnitz - Distributed Bloom Filter — Mantis - Event Querying — Passport — Device Types — Sharding
  • 44. Scaling Patterns for Netflix’s Edge Justin Ryan Passport
  • 45. Scaling Patterns for Netflix’s Edge Justin Ryan Service Plan API L7Proxy Mid Tier A Mid Tier B Mid Tier C Passport
  • 46. Scaling Patterns for Netflix’s Edge Justin Ryan Passport Service Plan API L7Proxy Mid Tier A Mid Tier B Mid Tier C
  • 47. Scaling Patterns for Netflix’s Edge Justin Ryan Cache Service Plan API L7Proxy Mid Tier A Mid Tier B Mid Tier C
  • 48. Scaling Patterns for Netflix’s Edge Justin Ryan Cache API L7Proxy Mid Tier A Mid Tier B Mid Tier C Service Plan
  • 49. Scaling Patterns for Netflix’s Edge Justin Ryan Cache API L7Proxy Mid Tier A Mid Tier B Mid Tier C Service Plan
  • 50. Scaling Patterns for Netflix’s Edge Justin Ryan Passport
  • 51. Scaling Patterns for Netflix’s Edge Justin Ryan Passport Trade Offs — Data Passing — Heavy Data Structures
  • 52. Scaling Patterns for Netflix’s Edge Justin Ryan Five Use Cases — Melnitz - Distributed Bloom Filter — Mantis - Event Querying — Passport - Heavy Data Structure — Device Types — Sharding
  • 53. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types
  • 54. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types NFAPPL-01-IPAD7=5-09BEC57F64CA5F837C75F924B94D NFAPPL-01-IPAD3=4-15B2D9B33A994CC373017A9C6586 NFAPPL-02-IOS2=4-FT7WHG8H2UR2MCJ4YKR3P0DFH6 NFANDROID1-PRV-P-GOOGLPIXEL=2-7351-0F441DF98B8D99074 NFANDROID1-PRV-4339-0E50FC7582396F5C4496ED935F2F48ED 1395 1007 964
  • 55. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types
  • 56. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types
  • 57. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types Mid-Tier F Mid-Tier E Mid-Tier D Mid-Tier C Mid-Tier BMid-Tier A DTS
  • 58. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types Mid-Tier CMid-Tier BMid-Tier A DTS PubSub
  • 59. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types Mid-Tier CMid-Tier BMid-Tier A DTS PubSub Device Types Device TypesDevice Types
  • 60. Scaling Patterns for Netflix’s Edge Justin Ryan Device Types
  • 61. Scaling Patterns for Netflix’s Edge Justin Ryan Device Type Trade Offs — Business Tuned Fallbacks — Leverage Existing Infrastructure
  • 62. Scaling Patterns for Netflix’s Edge Justin Ryan Five Use Cases — Melnitz - Distributed Bloom Filter — Mantis - Event Querying — Passport - Heavy Data Structure — Device Types - Device Grouping — Sharding
  • 63. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding
  • 64. Scaling Patterns for Netflix’s Edge Justin Ryan MSL — Message Security Layer == MSL — Secure Messaging Framework
  • 65. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding MSL L7Proxy APIAPIAPIAPIAPIAPI
  • 66. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding MSL L7Proxy MSL APIAPIAPI
  • 67. Scaling Patterns for Netflix’s Edge Justin Ryan CPU Cost Per Request - CPU to RPS ratio - Load Average 31% decrease
  • 68. Scaling Patterns for Netflix’s Edge Justin Ryan Latency 30% decrease 20% p99 decrease
  • 69. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding MSL
  • 70. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding MSL - % of Wall Clock in GC - GC Pause Time
  • 71. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding MSL - Average Latency - 99% Latency
  • 72. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding 3 = 1 + 1
  • 73. Scaling Patterns for Netflix’s Edge Justin Ryan Sharding Trade Offs — Operational Overhead
  • 74. Scaling Patterns for Netflix’s Edge Justin Ryan Five Use Cases — Melnitz - Distributed Bloom Filter — Mantis - Event Querying — Passport - Heavy Data Structure — Device Types - Device Grouping — Sharding - Runtime Refactoring
  • 75. Scaling Patterns for Netflix’s Edge Justin Ryan Trough
  • 76. Scaling Patterns for Netflix’s Edge Justin Ryan Trough - Used Instances - Reserved Instances
  • 77. Scaling Patterns for Netflix’s Edge Justin Ryan Pattern #6 Trough — Leverage Unused Resources
  • 78. Scaling Patterns for Netflix’s Edge Justin Ryan Trade Odds ● Probabilistic Data Structure ● Off the Shelf Components ● Avoid Work ● Scale Solution to Zero ● Data Passing ● Heavy Data Structures ● Leverage Existing Infrastructure ● Business Tuned Fallbacks ● Runtime Refactoring Melnitz Melnitz Mantis Mantis Passport Passport DTS DTS Sharding
  • 79. Scaling Patterns for Netflix’s Edge Justin Ryan When to Use Debuggability ✗ ✓ ✓ ✓ ✓ ✗ Infrastructure ✓ ✗ ✗ ✓ ✗ ✗ Managing ✗ ✗ ✗ ✓ ✗ ✗ Costs ✓ ✓ ✗ ✗ ✓ ✓ Melnitz Mantis Passport DeviceTypesSharding Trough
  • 80. Scaling Patterns for Netflix’s Edge Justin Ryan Bonus Trade Offs — Do the laundry
  • 82. Scaling Patterns for Netflix’s Edge Justin Ryan References — github.com/Netflix ◆ eureka ◆ zuul ◆ mantis ◆ msl — Spinnaker — Apache Pulsar — Google Guava (Bloom Filter)
  • 83. Watch the video with slide synchronization on InfoQ.com! https://www.infoq.com/presentations/ netflix-edge-scalability-patterns/