Scalability
Problem
How do I scale my application so that it is not a victim of its own success?
Solution
Speed is critical. If your application does not load within milliseconds, it will tend to drive away users. Given the viral nature of Facebook, such a scenario can occur within weeks or even days of launching your application. Scalability needs to be ingrained within all aspects of the application: source code, database, hardware/operating system platform, user interface, and support systems. As there is no fixed formula for scalability, you need to monitor these aspects closely and tune the ones that you think will cause a bottleneck. Build your application to sustain at least three times more load than you initially expect.
Discussion
When we launched Scrabulous on Facebook in June 2007, we did not expect more than a few thousand users. Accordingly, Scrabulous was launched on a shared-hosting service and utilized a common database server with possibly 50 other websites. Two weeks into our launch and with less than 10,000 users on Scrabulous, we were introduced to the word “scalability.” Our hosting service politely asked us to remove the application from their servers as it was causing a large amount of load! Even today, after having rewritten the entire source code four times and moving onto private dedicated servers, we still need to consider the scalability factors before launching a new feature on Scrabulous. For your application, ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access