Learning Objectives
Understand what a Workload is
Understand how Workloads help developers manage sets of pods
Learn how to make informed decisions about workload strategies
Now Tommy has a standardised way to package his ingredients, kitchen utensils and any other equipment needed for making his famous burger.
His next challenge is to resolve how the prep chefs in the kitchen make the burger available to the customers.
Customer satisfaction is important to Tommy’s business, and he therefore recognises that customers will want flexibility and customisations when ordering from his menu.
In order to succeed however, Tommy still needs to have a standardised way to handle these customer requests.
- Workload: This refers to the things that you want to run on a Kubernetes cluster like applications, services or batch jobs. It can be a single container or a group of containers that make up a distributed application.
- As developers are the ones who created the code, it makes sense for them to be able to define to the users what can and cannot be requested from their application. For example, the chef would write a detailed menu as they are the ones who understand the dishes best.
- Workload resources make it much easier for developers to manage sets of pods, instead of having to manage each pod directly. They also provide a way to tell your container orchestration platform (e.g. Kubernetes) how to run your code. More on that later...
If Tommy can clearly define what the customers can request from the menu, this will bring a number of benefits. Let’s take a look at those benefits.
In the restaurant, Tommy can easily update the menu and have it reflected in the restaurant's operations. New food items can be added, recipes can be modified or dishes removed, without disrupting the overall functioning of the kitchen.
In Tommy’s restaurant you can plan by specifying how much of each food item should be prepared, how many servings to make and when to start cooking.
Prep chefs can define their desired state for each patty in a detailed recipe and let the digitised restaurant management system that Poppy setup calculate the logistics of what ingredients are required and which table to send them to. The table chef can then cook to perfection.
- Flexibility: Defining Workloads makes it easy for developers to apply updates and changes without disrupting existing workflows.
- Organisation: As Workloads provide detailed instructions of how to run each audio request, this information can be used to make development more efficient.
- Standardisation: Workloads provide standardised definitions of how to deploy a developer's code, including all the details of how to deploy any corresponding containers.
- Container Orchestration: Kubernetes uses Workloads to automatically deploy and manage containers, finding the most efficient and organised way to do this.
In summary, Workloads provide standardised definitions of how to deploy a developer's code, including all the details of how to deploy any corresponding containers. Defining Workloads in this way make it easy for developers to make updates and changes without disrupting existing workflows. A container orchestration system such as Kubernetes can then use this information to automatically deploy and manage containers, finding the most efficient and organised way to do this.
In this section we learned...
A Workload describes what can be requested from code
Workloads can be easily adapted by developers without disrupting existing workflows
Defining Workloads means developers can organise the containers needed without any bottlenecks or delays
Workloads help to standardise all requests that can be made from the code so any developer can deploy them regardless of their current subject knowledge
Now we can define what can be requested from code using Workloads, we will next look at how we can use Kubernetes to efficiently deliver Workloads.