Oh, now what? Another technobabble name - megaservice! What is a megaservice?
A megaservice is a microservice that is capable of processing up to one million logical operations per second. In this context, the service prefix indicates the expected maximum sustained per second logical operation throughput.
In this talk, we will look at the more common deca-service (tens of LOPS), hecto-service (hundreds of LOPS), and kilo-service (thousands of LOPS) implementation techniques. We examine some of the common performance bottlenecks and look at methods to push services to higher throughput levels.
I'll share our experiences with a demo microservice application that we are using to push the cloud service providers to their limits. The demo application is composed of two Akka CQRS microservices. The app provides an interactive world map UI that visualizes IoT devices' distribution spread across the planet. With the click of the mouse, we generate thousands, tens of thousands, even millions of IoT devices and observe how various databases and cloud systems react when push to the limit.
All of the application code is built using OSS such as Akka, Java, JavaScript, and Kubernetes. The demo app is available for you to use as a learning tool for building your megaservices.
5. 5
Where on Earth (WoE)
Akka Microservices IoT Demo Application
Live Demo
6. What is a megaservice?
A megaservice is a microservice that is capable of
processing millions of logical operations per second.
In this context, the service prefix (mega)service indicates
the expected maximum sustained per second logical
operation throughput.
6
7. Measuring services on throughout vs complexity
deca-service 10s
hecto-service 100s
kilo-service 1,000s
mega-service 1,000,000s
LOPS - logical operations / second
7
8. Logical operations per second
IoT
Create or delete device
Change the device state
Shopping cart
Add item to cart
Change item quantity
Remove item from cart
Add shipping or billing address
Place order
8
9. Logical operations per second
Each LOPS may involve one or more
service operations
Each service operation may involve one or more
database operations
Each service operation may involve one or more
external service operations
9
77. 77
Where on Earth (WoE)
Akka Microservices IoT Demo Application
Live Demo
78. How Fast is Fast Enough?
Amazon average sales / second in 2020? $10,000
Assume average order size $50 - 10,000 / 50 = 200
~200 orders / second
IoT devices - 1,000,000
Telemetry message rate / IoT device - 1 / minute
Average device state change every 10 minutes - 1,000,000 / 60 / 10 = 1,667
~1,667 IoT state changes / second
78
We need more Speed!
79. How Fast is Fast Enough?
Alibaba Singles Day - 11/11
$1.49 billion in first 111 minutes on Nov 11, 2020
$1.49B / 111m / 60s = $223,724 sales / second
$223,724 / $25 avg sale
8,949 orders / second
Where will we be in 2025? 2030?...
79
We need more Speed!
80. WoE - Where on Earth Github repos
https://github.com/mckeeh3/woe-sim
https://github.com/mckeeh3/woe-twin
READMEs are WIP
Projects currently under active development
80
81. “Crop Circle” Akka Cluster Visualizer Github repos
https://github.com/mckeeh3/akka-cluster-kubernetes-simulator
https://github.com/mckeeh3/akka-cluster-kubernetes-visualizer
READMEs are WIP
Projects currently under active development
81