A non-technical explanation
I was recently having dinner at Pizarro’s, our favorite pizza parlor in Houston. This time we happened to visit the West Gray location, where I noticed they had 2 ovens, compared to the 1 oven at the Katy Freeway location we usually frequent. That’s when it occurred to me it would be fun to try and explain scalability using a pizza oven analogy.
As a software consultant, I often find myself explaining complex cloud concepts to clients who are non-technical, and it always helps to break it down in a way that everyone can relate to. For added context, this topic often comes up when we’re trying to help a client optimize their cloud spend, or the performance of their applications or virtual machines.
The Pizza Parlor Setup
In this article, think of the oven as a cloud resource, such as a virtual machine, a web server or a database. The pizza itself is the workload, something that is going to be prepared or created by the above resource. This could be a running workflow, a calculation, a procedure, or a data import or export operation.
Oven properties:
- Size: Ovens come in different sizes
- Cost: It costs money to operate an oven, bigger ovens cost more money etc…
- Capacity: The oven size we’re using in this example can hold 4 pizzas at a time
- Throughput: it can cook all 4 pizzas in 90 seconds (2.6667 pizzas per minute)
Pizza properties:
- It takes 90 seconds to perfectly cook Pizarro’s Napoletana pizza in their 900 degree wood fired oven
Scalability
For simplicity’s sake, we’ll ignore the time it takes to prepare a pizza or to take it in or out of the oven, and only focus on cooking time, 90 seconds. We’re also assuming that all oven sizes run at the same temperature and take the same amount of time to cook a pizza.
Since their throughput with the 2 ovens is less than 3 pizzas per minute, they would have to scale up, or scale out, in order to meet higher demand, like 5 or 10 pizzas per minute. But what do those two terms mean?
Scale Up: Also known as vertical scaling, is to basically make the oven bigger, so it can handle more pizza pies at once. The opposite, scaling down, makes the oven smaller. In the cloud, scaling up means making a resource more powerful, such as upgrading a virtual machine by adding memory (RAM) or processing power (CPU) or bigger and faster disk drives.
Scale Out: (or horizontal scaling) is to add more ovens, typically identical to the existing ones. The opposite would be Scaling In (less ovens). In the cloud scaling out means adding more virtual machines, databases, or application servers to split the workload across multiple identical resources. Unlike Scaling Up, where the same resource becomes more powerful to handle the growing workload, when you scale out, you split the workload across multiple identical resources.
The outcome is somewhat similar, but deciding when to scale up vs. out can be a very complex decision that involves several key parameters, including:
- Architectural Elasticity
- Seasonality and Workload Predictability
- Scaling Flexibility
- Long Term vs. Short Term growth expectations
- Data models & Dependencies
- Geographical Distribution
With over 20 years of expertise in software development and database consulting in the Oil and Gas industry, Mi4 is dedicated to delivering innovative and reliable solutions tailored to the business needs of our clients. Our comprehensive services range from custom software development and data analytics to cloud infrastructure management.
For more information or to discuss how we can assist with your next project, please contact us using this form.
