Kundenname, Präsentationstitel
BUILDING SCALABLE WEB APPS
ABOUT ME
Matías E. Fernández @matiasfrndz
Head of Systems and Development
WHAT DOES “SCALABLE” MEAN?
≠ efficient usage of CPU
≠ efficient usage of bandwidth
≠ efficient usage of storage
≠ fast page loads in browser
SCALABILITY ≠ PERFORMANCE
WTF?
SCALABILITY
In electronics (including hardware, communication and software), scalability is the ability of a system, network, or process to handle a growing amount of work in a capable manner or its ability to be enlarged to accommodate that growth.
en.wikipedia.org/wiki/Scalability
VERTICAL VS. HORIZONTAL SCALABILITY
VERTICAL SCALING
Bigger, faster, stronger!
HORIZONTAL SCALING
Start small …
HORIZONTAL SCALING
HORIZONTAL SCALING
Think BIG!
WHY BOTHER?
Because web startups tend to die
or grow … really big!
EXAMPLES
YOUTUBE• Founded in 2005 in a garage
• Officially launched in December 2005 with 8 million videos watched per day
• 100 million views a day in July 2006
• Over 4 Billion videos viewed per day in January 2012
• 72 hours of video uploaded every minute in May 2012
x 12 in7 month!
YOUTUBE
1 mio
10 mio
100 mio
1'000 mio
10'000 mio
2005
2006
2012
YouTube videos watched per day
Notice the logarithmic scale, bro?
• Founded in March 2006
• Officially launched in July 2006
• 400’000 tweets per quarter in 2007
• 100 million tweets per quarter in 2008
• 65 million tweets per day in June 2010
• 140 million tweets per day in March 2011, 1’600 tweets per second
x 230 in12 month!
1'000
10'000
100'000
1'000'000
10'000'000
100'000'000
2007
2008
2010
Tweets per day
Recognise the scale?
BETTER BE PREPARED
Rewriting your web app to be scalable
and
at the same time scale it to accommodatea 10 to 100 fold of customers
in 12 month?
Sounds like a challenge!
PLAYING FOR TIMEStrategies to Scaling out a Non-Scalable Web App
Semi
KEEP THINGS SIMPLE
Add caching reverse proxy to reduce theload on your web app and server
HTTP Accelerator
WE ALL START SMALL
Separate database and app server to gainCPU and I/O-performance
App Server
Database Server
LET’S START THE PARTY
App Servers
Redundant Load Balancerw. HTTP Acc.
We still needour database
SCALE OUT
vertically
verticallyhorizontally
SINGLE POINT OF FAILURE
They call me single pointof failure
REDUCE SPOF
2-Node FailoverCluster highly availability
✔
Kundenname, Präsentationstitel
Nine Internet Solutions AG
Albisriederstr. 243a
CH-8047 Zürich
Tel +41 44 637 40 00
Fax +41 44 637 40 01
QUESTIONS?
Top Related