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
Ludicrous speed
Search
Sergey Vysotskiy
December 09, 2014
Technology
0
28
Ludicrous speed
Fantastic stories about performance requirements
Sergey Vysotskiy
December 09, 2014
Tweet
Share
More Decks by Sergey Vysotskiy
See All by Sergey Vysotskiy
Embracing the Imposter
ggame
0
42
Pressing Play at Spotify
ggame
0
61
Testing for capacity
ggame
2
220
Software Industry 101 (2013 season): Красочный мир тестирования
ggame
0
110
Latency
ggame
1
160
Швейцарский нож для Android
ggame
0
270
Анатомия ошибки
ggame
0
290
Other Decks in Technology
See All in Technology
Terraform Stacks入門 #HashiTalks
msato
0
360
Why App Signing Matters for Your Android Apps - Android Bangkok Conference 2024
akexorcist
0
130
Engineer Career Talk
lycorp_recruit_jp
0
190
[CV勉強会@関東 ECCV2024 読み会] オンラインマッピング x トラッキング MapTracker: Tracking with Strided Memory Fusion for Consistent Vector HD Mapping (Chen+, ECCV24)
abemii
0
230
SRE×AIOpsを始めよう!GuardDutyによるお手軽脅威検出
amixedcolor
0
200
『Firebase Dynamic Links終了に備える』 FlutterアプリでのAdjust導入とDeeplink最適化
techiro
0
160
TypeScriptの次なる大進化なるか!? 条件型を返り値とする関数の型推論
uhyo
2
1.7k
DynamoDB でスロットリングが発生したとき_大盛りver/when_throttling_occurs_in_dynamodb_long
emiki
1
450
Shopifyアプリ開発における Shopifyの機能活用
sonatard
4
260
強いチームと開発生産性
onk
PRO
35
12k
EventHub Startup CTO of the year 2024 ピッチ資料
eventhub
0
130
Platform Engineering for Software Developers and Architects
syntasso
1
520
Featured
See All Featured
Keith and Marios Guide to Fast Websites
keithpitt
409
22k
Fashionably flexible responsive web design (full day workshop)
malarkey
405
65k
A Philosophy of Restraint
colly
203
16k
It's Worth the Effort
3n
183
27k
What's new in Ruby 2.0
geeforr
343
31k
Designing the Hi-DPI Web
ddemaree
280
34k
How to Think Like a Performance Engineer
csswizardry
20
1.1k
Code Review Best Practice
trishagee
64
17k
Designing Experiences People Love
moore
138
23k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
47
2.1k
Designing for Performance
lara
604
68k
Unsuck your backbone
ammeep
668
57k
Transcript
fantastic stories about performance requirements Ludicrous Speed
None
None
None
None
None
PANIC!
Modern human experimentations
None
None
Big business impact Big response delay
No silver bullets today
Perception of time What happens on internets? What is “OK”
response time? What is “OK” load? Summary PLAN
Perception of time What happens on internets? What is “OK”
response time? What is “OK” load? Summary PLAN
Perception of time What happens on internets? What is “OK”
response time? What is “OK” load? Summary PLAN
Perception of time What happens on internets? What is “OK”
response time? What is “OK” load? Summary PLAN
Perception of time What happens on internets? What is “OK”
response time? What is “OK” load? Summary PLAN
Perception Of Time
100-200 ms 500-1000 ms 2-5 seconds 7-10 seconds instantaneous reaction
uninterrupted reaction some reaction oof…
100-200 ms 500-1000 ms 2-5 seconds 7-10 seconds instantaneous reaction
uninterrupted reaction some reaction oof…
100-200 ms 500-1000 ms 2-5 seconds 7-10 seconds instantaneous reaction
uninterrupted reaction some reaction oof…
100-200 ms 500-1000 ms 2-5 seconds 7-10 seconds instantaneous reaction
uninterrupted reaction some reaction oof…
100-200 ms 500-1000 ms 2-5 seconds 7-10 seconds instantaneous reaction
uninterrupted reaction some reaction oof… *20 years old data
Modern data?
3… may be 5 seconds max
3… may be 5 seconds max Even faster in future
Weber–Fechner law 1 2
Weber–Fechner law 1 2
Weber–Fechner law 1 2
Weber–Fechner law 1 2
Weber–Fechner law 1 2 just noticeable difference (jnd)
Weber–Fechner law just noticeable difference (jnd) For time lengths of
up to 30s - jnd is somewhere between 7% and 18%
Weber–Fechner law Faster Slower
Weber–Fechner law 20s Faster Slower
Weber–Fechner law 20s 24s 16s -20% +20% Faster Slower
“Slightly” faster
Perception of average between t1 and t2 is: sqrt(t1*t2)
Example
Benchmark against 30s 60s less than 36s less than 42s
less than 24s slow same slightly slower faster
Benchmark against 30s 60s less than 36s less than 42s
less than 24s slow same slightly slower faster
Benchmark against 30s 60s less than 36s less than 42s
less than 24s slow same slightly slower faster
Benchmark against 30s 60s less than 36s less than 42s
less than 24s slow same slightly slower definitely faster
Is it worth to optimise? Target performance Unnoticeable degradation
Is it worth to optimise? Target performance Unnoticeable degradation
Is it worth to optimise? Target performance Unnoticeable degradation
Why so serious?
Why so serious?
What Happens on Internets?
None
None
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering on browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering on browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering on browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering on browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering on browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering on browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering in a browser
Response time: DNS request Establish TCP connection Generate request to
server Send request to server Server generates response Server sends response Page rendering in a browser
Fun facts! Min time to pass 1/2 of globe: 67ms
Later ;) Server generates response
Let’s talk a bit about that Page rendering in a
browser
In a complex projects 60% of time could be easily
spent on rendering
There’s space to optimise
There’s space to optimise
There’s space to optimise
Time budget: Load and render critical parts first
What Is “OK” Response?
It depends
In general case response longer than 300ms means nobody cares
In general case response longer than 300ms means nobody cares
Usually it’s more than 1 second on a client
It should be fast
It should be fast Bad requirement
It should be faster than 300ms
It should be faster than 300ms Bad requirement
Long tail
95% < 300ms 99% < 500ms
95% < 300ms 99% < 500ms
95% < 300ms 99% < 500ms OK requirement
95% < 300ms 99% < 500ms OK requirement But still
depends
Remember about 20% difference!
Remember to measure competitors!
Oof… Done with time!
Oof… Done with time! There are 1 more to go
What Is “OK” Load?
What measurement units to use?
What is “average user”?
“Average human” have less than 1 arm
Requests Per Second (RPS) is what server understands
How much RPS we should be able to handle?
EXTREMELY HARD QUESTION
Pulse of the Web
Spotify Average Monday in Stockholm
Spotify Specific Monday in Stockholm
None
None
None
None
Spotify Average Monday in Eastern US
Financial Times weekly traffic changes
Financial Times weekly traffic changes Extremely different for different clients
Financial Times weekly traffic changes Extreme daily features
Thanksgiving in US Events could make a big difference
Bombing in Moscow subway 29 march 2010
Bombing in Moscow subway 29 march 2010 First explosion 7:57
Load growth 8:10
Think like a user Look for daily/weakly/yearly cycles
Think like a user Look for daily/weakly/yearly cycles
Event based service? Prepare for extremely huge spikes
Do closed beta And watch for load profile
It’s growing
Very Short Summary
Find out what is OK response time for you Remember
about long tail Find out possible max load Test your assumptions
Find out what is OK response time for you Remember
about long tail Find out possible max load Test your assumptions
Find out what is OK response time for you Remember
about long tail Find out possible max load Test your assumptions
Find out what is OK response time for you Remember
about long tail Find out possible max load Test your assumptions
APPLAUSE
QUESTIONS?
Magic Numbers Some
4 datacenters More than 5K servers ~50 millions of unique
users More than 100 people working on backend infrastructure and operations
DATACENTERS: Ashburn San Jose Stockholm London
QUESTIONS?
Sergey Vysotskiy
[email protected]