A friend of mine tells me a story repeatedly. Back in 2003/4, he co-wrote an online news aggregation web app when RSS feeds were first taking off. The app had every social news application feature that you could think of. Imagine Digg + StumbleUpon + Google News all in one (and in 2003 !). Things were going great guns until the time a popular internet celebrity chose to write about the site. A couple of hours later, the site crashed in the middle of the night. Next morning, the negative reviews started. A large number of users reported the site was down or slow to respond. My friend was never able to capitalize on a viral uptake in user base.
Consumer-facing applications can go viral very quickly. If an application is accessible via a smartphone interface, the power of social media can fuel exponential growth of your user-base as well as data.
Monolithic applications fail to scale up to the demands of a growing business. The failure of these applications in responsiveness and scalability results in customer dissatisfaction leading to loss of brand value and of course revenue.
The above graph shows Airbnb’s user base expand virally between May and August 2011. They added close to 500,000 users in the space of 3 months. A similar but more recent example is Twitter’s Periscope app which racked up more than 1 million users just 10 days after launch. It would be extremely difficult to take care of such swift scale in traffic without a cloud deployment.
In this series of blog entries, we will take a look at some of the aspects that help us build a scalable cloud-deployed application. In this first part, we will look at the advantages of building scalable applications that leverage the cloud.
The cloud provides the ability to scale on demand and with almost no practical limits. It is possible for infrastructure resources like CPU, memory and storage to be provisioned in a matter of minutes as opposed to hosting and operating those locally. In traditional on-premise data-centers, growth in demand has to be catered to by procuring new hardware. This is not only expensive, but may lead to over-provisioning of resources, not to mention the lead time required to setup and run.
As traffic spikes, cloud based applications can scale on-demand. You can even configure automatic scaling such that as the traffic spikes, resources are allocated and as the traffic declines the resources are relinquished. (We will look at Auto-scaling in details in future posts of this series). This helps the application use excess capacity only when needed.
Cloud adoption cuts down your Capex costs in a big way. It does not require a significant up-front capital expenditure and requires considerably few internal resources to maintain and administer. Operating costs in a cloud environment can be monitored and controlled as per your budgets.
Cloud platforms do not need any up-front commitment by users. Most cloud platforms allow you to pay for actual resources consumed. Resources like compute (CPU) are usually billed on a per-hour usage model whereas other resources like network or storage are billed on bandwidth and storage consumed. This approach takes away a large component of any upfront payments for businesses. It also levels the playing field, allowing smaller companies or even individuals to start cloud businesses that succeed.
Be it an established business house or an individual entrepreneur, one advantage of the cloud that excites everyone, is the ability to push products to the market faster. Traditionally it takes anywhere between 6-8 weeks for IT server provisioning. Compare this to the cloud that can provision the IT resources in a matter of hours if not minutes.
Cloud platforms have presence in multiple regions. Each region is a distinct geographic area which in turn has multiple, isolated data centers. Applications hosted in cloud can be deployed on multiple data centers in order to make them highly available. Since the application is not dependent on one physical location, outages such as loss of network or electricity do not translate to application downtime.
To protect against natural disasters and calamities, applications can also be hosted in multiple regions using data replication and DNS failover. This allows applications to survive outages of complete regions, by restoring business operations quickly with minimal downtime. Providing disaster recovery solutions using traditional means was reserved for the deepest pockets before the cloud arrived.
Cloud adoption has allowed organisations to scale faster to the needs of a growing business without the headache of managing infrastructure. It is no wonder that cloud has become an integral part of any scalable application. Coupled with “pay as you go” pricing and economies of scale, cloud vendors provide incredible value for computing needs that cannot be ignored.
Architecture for applications on the cloud is a different ball-game and involves various components in tiers that need to be put together to create a functioning application. In our next post, we will delve into the design aspects of a scalable cloud application. Stay tuned!