01 Cloud Computing Evolution, 02 Feet in the Cloud

Compute on Demand: Virtual Servers

Reading Time: 5 minutes

7 years later (2018), and after becoming a real expert with AWS and distributed systems, I gave a lecture about cloud computing evolution titled “From Servers to Serverless” in front of about 150 students, engineers and entrepreneurs. I told them these stories and they laughed hard. It was ancient history to them.

“Please raise your hands”, I asked the audience, “if you currently have 3,000 US dollars in your pocket to buy a bare metal server and to launch your startup with nothing but an idea that will not produce any income in the upcoming future”. Needless to say that no hands were raised. “Please raise your hands”, I asked the audience again, “if you know of a VC that’s willing to wait for 3 months with its investment because you need to buy a server”. Yet again no hands were raised.  “That’s good, because you don’t need to!”.

Cloud computing is one of the main reasons for the startup era/boom. Today, you can get an instance of a server, a virtual server, on AWS within minutes and pay about 120$ a month (and there are free ones as well!). Even if it turns out after three months that your idea was bad, and it mostly is, you’ve only lost a few hundreds dollars instead of thousands. These three months were better spent on actual development and not waiting for a server delivered.

That is also zero time spent on setting up, fixing and maintaining these bare metals, which you don’t really know how to do. You weren’t a brave soldier in the Israeli Army like me. Who is going to plug in those servers? Who is going to backup and replace those hard drives? “Don’t care, not my problem!”. The hardware, the bare metals are no longer your concern. It is now your Cloud provider’s responsibility to maintain it for you. You’ve outsourced it to someone who will do it better than you ever will, that is higher resiliency. That is what is called IaaS – Infrastructure as a Service.

What is true for a small startup is also true for large enterprises who need to run and maintain an entire data center, hundreds and thousands of servers. This would require them to hire tens of engineers. You’d notice that I did not say software enterprises, as not all are. Many are commerce (Sears, McDonalds), insurance or tourism enterprises. Cloud Computing allowed these enterprises to outsource a huge portion of their operations and save millions of dollars. These dollars saved are now better invested into profitable streams, into the money makers, such as marketing efforts.

Gimme more please!

Unlike bare metals, you can “buy and sell” virtual servers as many as you want and when you need it. Your fleet server size and compute power is not fixed in time. It is dynamic. This opens up a whole new world. I’ll start with an actual use case.

You are a retailer, a very good one to say the least, that sells lots of shoes online. Shoes are your money makers. Every year on Black Friday the same thing happens again and again – your bare metal servers go down for a few hours due to high traffic / high demand and you lose tons of actual money from unmade sales. A day after you round up your IT department demanding that next year it will not happen again. “No problem”, they’d say, “we’d need to buy 40 more servers. It would cost about $200k”. That is a whole lot of shoes. These are not preposterous numbers at all.

The IT is not wrong. You needed 20 to statify’s this year’s traffic, so it will be double that to satisfy next year’s traffic. You’d be right to be mad as it doesn’t make sense to pay that much for just that one weekend. You won’t be needing this extra capacity for 95% of the time, but it is not IT’s fault. Back then, before cloud computing, you didn’t have a choice. You had to buy servers/resources in advance and to plan for max capacity. 

What happens to your sales supposedly annually on Black Friday, also happens in other time frames. On a weekly basis you’re getting traffic surges on Fridays and lost traffic on Sundays. On a daily basis you’re getting traffic surges only between 8pm and 9pm.

To better explain it, let’s have a look at this made up graph:

The graph shows the number of requests per minute (rpm, Y axis) on a daily basis. For simplicity, the example would treat a day as a whole. Let’s presume that each 1k rpm requires one server. 

Between Monday to Thursday, your website’s traffic is quite normal, around 1.5k rpm which would require 2 servers to satisfy. On Sundays the traffic is very low, about 0.2k rpm and 1 server is enough. Fridays and Saturdays are peak days with almost 2.5k rpm, so a total of three servers would do the trick.

The first serveris used for seven days, a 100% of the time [you’d later see that this is incorrect, for simplicity sake]. The second server is needed for only 6 out of 7 days (85%). The third server is needed for one day only (15%).

If your fleet server size is fixed, you’d need to plan for max capacity and buy 3 servers in advance (the red line). A single cheapest virtual server costs $120 a month. An annual cost of running a single server is $1,440 and three servers is $4,320. If your fleet server size would have been dynamic, you’d be paying only for the actual time they were needed (1 + 0.85 + 0.15) * $1,440 = $2,880. 33% lower.

It is not only about costs, but also about resilience. Let’s presume that your marketing campaign has suddenly launched, without telling anyone, a very successful campaign on the weekend that doubled the number of requests per minute for 5 hours. A fixed fleet size of 3 servers wouldn’t be able to handle it and it would crash. A dynamic fleet size that would automatically adjust the number of servers needed almost minute-by-minute, would make sure that crash will not happen.

So not only can your website withstand any amount of traffic without knowing surges in advance, it will do so for less costs and with less maintenance. You are happy, your customers are happy and your cloud provider is happy. Everybody wins.

Dynamic fleet size is better known as Auto Scaling and it is a very important feature required for a resilient system as it allows you to withstand any kind of traffic increase. Both expected ones, such as growth in installations or holidays, and unexpected ones such. The added costs are marginal, as you pay for only what you need and still it would be lower than the cost of a failure, the cost of lost sales.

That was just the beginning of Cloud Computing. You no longer need to have your own data center full of bare metals and you’ve gained resilience to traffic, but there is more resilience and happiness to gain, for even less maintenance.

Leave a Reply