With the adaptation of building applications using a microservices architecture with containerized solutions, Kubernetes has come into the picture. Often, when you attend a talk/seminar on containers and microservices, you come across Kubernetes either from the speaker or from the audience during the Q&A session. You might be wondering what Kubernetes is and what it has to do with building microservices or containerized solutions. If these are some of the questions coming across your mind, then read this article till the end. In this article, we are going to discuss,
-
What is Kubernetes?
-
What is Container Orchestration?
-
Why do we need Kubernetes?
-
Advantages of Kubernetes
-
Disadvantages of Kubernetes
What is Kubernetes?
Kubernetes is an open-source container orchestrator. It helps in automating the manual process involved in deploying, managing, and scaling a containerized solution
It was developed and open-sourced by Google back in 2015 and is currently maintained by the Cloud Native Computing Foundation as an open-source project. Kubernetes was built on top of Google’s years of experience in deploying applications to the production environment using an internal platform Borg. It is backed by many key industry players, including Redhat and Intel, to name a few.
Some cloud vendors have also rolled out their managed Kubernetes service. Some popular managed Kubernetes services are Azure Kubernetes Service, Google Kubernetes Engine, and Amazon EKS offered by different cloud vendors.
Kubernetes supports any container managers compliant with the Open Container Initiative (OCI) standards, a standard for container image formats and runtimes. Some of the popular container engines are Docker Swarm, Containerd, and Podman.
What is Container Orchestration?
Container orchestration refers to the management of individual containers through a virtual partition on the shared infrastructure. A container orchestration platform is responsible for handling service discovery, configuring and deploying the microservices to the worker nodes, and scale each microservice in an efficient compute effective way depending on the traffic.
Why do we need Kubernetes?
There can be questions arising in our mind, why do we need Kubernetes. When we create a complex application, it can have hundreds of containers running inside of a cluster. And when we plan to deploy it to a production environment, there are many things that we need to consider. Some of which are mentioned below,
-
Container interaction
-
Effective resource management
-
Scalability
-
Health-checks
-
Configure management
Some Kubernetes benefits are application replication, autoscaling, rollout, and rollback. With the help of health checks probes, Kubernetes helps us define if a container can be viewed as ready, alive, or failed. Kubernetes will route traffic to a pod/container instance only if it is healthy and ready. Along with that, it also monitors your worker nodes, pods, and container instances. In case any of them goes down, it restarts them and, if required, scales them up, too.
Kubernetes handles load balancing between different replicas of a workload. It uses an internal DNS and assigns a unique DNS record to establish communication between various services.
Advantages of Kubernetes
Below are some of the advantages of using Kubernetes for container orchestration,
-
Open-source
-
Health checks for pods
-
Efficient resource management
-
Supports different container engines
-
Availability with multiple cloud vendors
Disadvantages of Kubernetes
Below mentioned are some of the disadvantages of using Kubernetes for container orchestration,
-
Steep learning curve
-
Hard to install and configure
-
Not an idle choice for simple applications
Conclusion
Kubernetes is by far the most used and preferred container orchestration tool used in the industry now. It should not be surprising looking at all the end benefits it provides, like scaling, health checks, multi-container engine support. Though this can be easily missed, It is an open-source project. So if you find a bug in it or want to propose a new feature, you go to the Kubernetes
Github page and add a new features request or post the bug you were facing. But this container orchestration platform also comes with its share of pain points. The pain point of Kubernetes is the steep learning curve and can be over burn for building a simple application. This is a personal opinion, but all in all, Kubernetes has been a game-changer for the microservice world.