- Netflix evolved from a monolithic architecture to a microservices architecture due to bottlenecks from organizational growth and diverse functionality in the monolithic stack.
- Microservices address these issues by decomposing applications into independently deployable services but introduce new challenges around service discovery, communication between services, and failure handling.
- Netflix developed best practices for microservices including service discovery with Eureka, load balancing with Ribbon, failure mitigation with Hystrix, and reactive inter-process communication with RxJava and tools like Ribbon and Hystrix.
29. • Write programs that do one thing and do it well.
• Write programs to work together.
tr 'A-Z' 'a-z' < doc.txt | tr -cs 'a-z' 'n' | sort | uniq | comm -23 -
/usr/share/dict/words
Program to print misspelt words in doc.txt
57. Data Serialization Overhead
Service A Service B Service C Service D
getMovies() getMovie() getMovieMetadata(
)
C
l
i
e
n
t
D
C
l
i
e
n
t
C
C
l
i
e
n
t
B
Data
transformation
XAvroX
XmlJSON
Overall Response Time
58.
59.
60. A single “bad” service can still bring your service down
69. Account
Service 1
Recommendation
Service 1
Customer Service
Service 1
API Gateway
Account
Service N
Recommendation
Service N
Customer Service
Service N
Customer Service
Load Balancer
Reco Service
Load Balancer
Account Service
Load Balancer
ELB
70.
71. Account
Service 1
Recommendation
Service 1
Customer Service
Service 1
API Gateway
Account
Service N
Recommendation
Service N
Customer Service
Service N
Account Service
LB
Recommendation
Service LB
Customer Service
Service LB
ELB
76. How many dependencies does my service have?
What is the Call Volume on my Service?
Are any Dependency Services running Hot?
What are the Top N Slowest “Business Transactions”?
What are the sample HTTP Requests/Responses that had a
500 Error Code in the last 30 minutes?
92. Fault Injection Testing (FIT)
Device ELB Service B
Service C
Internet Edge
Device or Account Override
Zuul
Service A
Request-level simulations
Refer Re:Invent Talk “Embracing Failure: Fault Injection and
Service Reliability” – PFC305
96. • Netflix – background and evolution
• Monolithic Apps
• Microservices
– Challenges and Solutions
– Best Practices
• InterProcess Communication
97.
98. Netflix IPC Stack (1.0)
A
p
a
c
h
e
H
T
T
P
C
l
i
e
n
t
Eureka (Service
Registry)
Server (Karyon)
Apache
Tomcat
Client
H
y
s
t
r
i
x
E
V
C
a
c
h
e
Ribbon
Load
Balancing
Eureka
Integration
Metrics
(Servo)
Bootstrapping (Governator)
Metrics (Servo)
Admin ConsoleHTTP
Eureka Integration
Registration
Fetch Registry
A Blocking Architecture
99. Netflix IPC Stack (2.0)
Client (Ribbon 2.0)
Eureka (Service
Registry)
Server (Karyon)
Ribbon Transport
Load
Balancing
Eureka
Integration
Metrics
(Servo)
Bootstrapping (Governator)
Metrics (Servo)
Admin Console
HTTP
Eureka Integration
Registration
Fetch Registry
Ribbon
Hystrix
EVCache
R
x
N
e
t
t
y
RxNetty
UDP
TCP
WebSockets
SSE
A Completely Reactive Architecture
106. Talk Time Title
PFC-305 Wednesday, 1:15pm Embracing Failure: Fault Injection and Service Reliability
BDT-403 Wednesday, 2:15pm Next Generation Big Data Platform at Netflix
PFC-306 Wednesday, 3:30pm Performance Tuning EC2
DEV-309 Wednesday, 3:30pm From Asgard to Zuul, How Netflix’s proven Open Source
Tools can accelerate and scale your services
ARC-317 Wednesday, 4:30pm Maintaining a Resilient Front-Door at Massive Scale
PFC-304 Wednesday, 4:30pm Effective Inter-process Communications in the Cloud: The
Pros and Cons of Micro Services Architectures
ENT-209 Wednesday, 4:30pm Cloud Migration, Dev-Ops and Distributed Systems
APP-310 Friday, 9:00am Scheduling using Apache Mesos in the Cloud
107. • Netflix – background and evolution
• Monolithic Apps
• Microservices
– Challenges and Solutions
– Best Practices
• InterProcess Communication
• Takeaways