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
Handling Scale with Reactive Programming
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Alex Xandra Albert Sim
September 29, 2018
Technology
0
120
Handling Scale with Reactive Programming
Summary of reactive programming concept and basics
Alex Xandra Albert Sim
September 29, 2018
Tweet
Share
More Decks by Alex Xandra Albert Sim
See All by Alex Xandra Albert Sim
System Operations
bertzzie
0
76
The Future of Working in IT
bertzzie
1
91
Dependency Injection in Spring
bertzzie
0
81
Scala: Lessons Learned from the Battlefield
bertzzie
0
77
Lessons We Learned Through Hell When Scaling Blibli.com
bertzzie
0
240
Introduction to GraalVM
bertzzie
0
160
Building Fintech App in Java: Tips & Trick
bertzzie
0
170
Scaling Software Architecture: 101 and Best Practices
bertzzie
0
230
Spring Cloud Contract Introduction
bertzzie
0
650
Other Decks in Technology
See All in Technology
型を書かないRuby開発への挑戦
riseshia
0
190
開発組織の課題解決を加速するための権限委譲 -する側、される側としての向き合い方-
daitasu
5
260
Kiro のクレジットを使い切る!
otanikohei2023
0
110
Webアクセシビリティ技術と実装の実際
tomokusaba
0
230
Secure Boot 2026 - Aggiornamento dei certificati UEFI e piano di adozione in azienda
memiug
0
140
DX Improvement at Scale
ntk1000
3
300
20260305_【白金鉱業】分析者が地理情報を武器にするための軽量なアドホック分析環境
yucho147
1
180
Kaggleで鍛えたスキルの実務での活かし方 競技とプロダクト開発のリアル
recruitengineers
PRO
1
160
モブプログラミング再入門 ー 基本から見直す、AI時代のチーム開発の選択肢 ー / A Re-introduction of Mob Programming
takaking22
1
100
Exadata Fleet Update
oracle4engineer
PRO
0
1.3k
Master Dataグループ紹介資料
sansan33
PRO
1
4.4k
kintone開発のプラットフォームエンジニアの紹介
cybozuinsideout
PRO
0
820
Featured
See All Featured
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
199
73k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
A Tale of Four Properties
chriscoyier
162
24k
The Mindset for Success: Future Career Progression
greggifford
PRO
0
270
Designing for Performance
lara
611
70k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
470
Java REST API Framework Comparison - PWX 2021
mraible
34
9.2k
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.7k
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
1
140
Information Architects: The Missing Link in Design Systems
soysaucechin
0
810
RailsConf 2023
tenderlove
30
1.4k
Transcript
Handling Scale with Reactive Programming Alex Xandra Albert Sim
Disclaimer Presentations are intended for educational purposes only and not
to replace independent professional judgment. The views and opinions expressed in this presentation do not necessarily reflect the official policy or position of blibli.com. Audience discretion is advised.
Who am I? • Alex Xandra Albert Sim • Principal
Research and Development Engineer at blibli.com •
[email protected]
• bertzzie(.sim)
Reactive Manifesto
Reactive Manifesto A good reactive systems are: • Responsive •
Resilient • Elastic • Message Driven
Reactive Manifesto A good reactive systems are: • Responsive •
Resilient • Elastic • Message Driven
Reactive Manifesto A good reactive systems are: • Responsive •
Resilient • Elastic • Message Driven
Reactive Manifesto A good reactive systems are: • Responsive •
Resilient • Elastic • Message Driven
Reactive Manifesto A good reactive systems are: • Responsive •
Resilient • Elastic • Message Driven
ACHIEVING RESPONSIVENESS
The Classic Web Architecture
The Classic Web Architecture
The Normal Flow Users Internet Web app (tomcat, netty, php,
etc) Application process
What’s in “application process”?
Classical Code Sample
Classical Code Sample
Potensi Bottleneck
Little’s Law ! = # × % L : Jumlah
koneksi ke database λ : Load dari request W : Waktu respons database
Little’s Law (Contoh) Untuk kasus di mana: • Terdapat 500
request / detik • Database memberikan response dalam 30ms • Jumlah koneksi db yang diperlukan adalah 15 L = λ x W L = 500 rps x 0.03s L = 15
Alur Kehancuran Sistem (1)
Solusi? • Naikkan jumlah pool / queue? • NO, karena
hanya membantu di average case • Kenapa? • DB down 1 menit, 500 rps tetap masuk
Solusi 1
Solusi 2
Solusi Queue • Membuat sistem konsisten. • Misal: 3 queue
berarti sistem akan memberikan respon max 120ms • Average menurun, tapi lebih stabil • Belum hitung cache! • + cache rate 50%, average bisa < 50ms
Queue dan Timeout • Timeout == batas sistem dianggap gagal
• Request tidak selalu terdistribusi rapi • Average tidak sepenting Max Response Time
ON PARALLELISM
Sequential Execution Start a b c Result Latency
Parallel Execution Latency Start a b c Result
Composable Future
Keterbatasan Parallelisme
Keterbatasan Parallelisme
What we miss L • Resilience: Compartmentalization • Resilience: Circuit
Breaker • Resilience: Supervision pattern • Message passing • Actor system • BASE Pattern
Maybe next time!
QUESTION AND ANSWERS
Come with us. We have cookies.
Thank You