aster.cloud aster.cloud
  • /
  • Platforms
    • Public Cloud
    • On-Premise
    • Hybrid Cloud
    • Data
  • Architecture
    • Design
    • Solutions
    • Enterprise
  • Engineering
    • Automation
    • Software Engineering
    • Project Management
    • DevOps
  • Programming
  • Tools
  • About
  • /
  • Platforms
    • Public Cloud
    • On-Premise
    • Hybrid Cloud
    • Data
  • Architecture
    • Design
    • Solutions
    • Enterprise
  • Engineering
    • Automation
    • Software Engineering
    • Project Management
    • DevOps
  • Programming
  • Tools
  • About
aster.cloud aster.cloud
  • /
  • Platforms
    • Public Cloud
    • On-Premise
    • Hybrid Cloud
    • Data
  • Architecture
    • Design
    • Solutions
    • Enterprise
  • Engineering
    • Automation
    • Software Engineering
    • Project Management
    • DevOps
  • Programming
  • Tools
  • About
  • Software
  • Software Engineering

5 Things Developers Need To Know About Kubernetes Management

  • aster_cloud
  • November 24, 2021
  • 5 minute read

Kubernetes management can be daunting for developers who don’t have specialized understanding of the orchestration technology. Learning Kubernetes takes practice and time, a precious commodity for devs who are under pressure to deliver new applications. This post provides direction on what you need to know and what you can skip to take advantage of Kubernetes. Let’s start with five things you need to know.

1. Kubernetes Naming Conventions

As a developer, understanding that objects created in Kubernetes must follow specific naming conventions will help you interpret insights more quickly. Knowing how these work and why something is named a specific way will help to make correlations when something might be wrong with the application or underlying infrastructure. Each Kubernetes object has a name that’s unique for a type of resource and a uniquely identified object (UID) that’s unique across an entire cluster. Kubernetes.io does a great job of explaining this by saying, “You can only have one Pod named myapp-1234 within the same namespace, but you can have one Pod and one Deployment that are each named myapp-1234.” In addition, pods that have the same higher-level controller (e.g. ReplicaSets/Deployments) will inherit the same naming prefix. For example, if your deployment name is ‘webapp,’ a corresponding ReplicaSet could be webapp-12345678, and the corresponding pod under that could be webapp-12345678-abcde. This way, every pod in this namespace has a unique name, but it is to tell which pods share the same controller and thus the same specification.


Partner with aster.cloud
for your next big idea.
Let us know here.


cyberpogo

2. How to Get Your Application to Run

New Kubernetes users should have a basic understanding of services and deployments as they factor into running applications.

Services are just a general way to route network traffic within the cluster, and sometimes from outside too. It’s fairly easy to define and allows easily human-readable configuration for where traffic goes. An example would be a service named ‘webapp’ that routes traffic to pods with the label ‘app: web.’ Any pod in the same namespace can make calls to the webapp pods by making a request to the URL ‘http://webapp’. Traditionally, in setting up networking, there are a number of steps that go into ensuring traffic routes to the right place, but using services in Kubernetes enables you to give directions at a higher level and the resulting action is automated.

Read More  New Relic Introduces Low-Overhead Kubernetes Monitoring

Deployments are the simplest high-level controller. In stateless applications, it is enough for developers to understand that deployments will handle rolling updates with simple instructions, such as how many copies you want and what version you’re on. This ensures that your application connects to the correct endpoints; everything in between happens automatically. For more complex applications, it may be worth exploring some of the other high-level controllers, like StatefulSets and Cron jobs.

It is also helpful to understand the main principle of containers: How do I get to a consistent state? If an update or action causes an application to get into a bad state, just restarting the container resets it. The container may not be on the same node, and you might not have the same set of interactions, but ultimately the most important things are the same as when you started.

3. How to Get Information About Your Application

Regardless of what infrastructure you are running on, this is what most developers care about. What went wrong, where did it go wrong, how critical is it and is it my problem? That last question may seem a bit cynical, but knowing which team and developer are best suited to solve a problem is crucial for operational efficiency. The primary questions you need answered are: How do I tell if my application is running, and what does resource consumption look like?

A helpful point to note is that employing the command “kubectl get events” will provide you with all of your application events. Unfortunately, Kubernetes doesn’t order them in any particular way, but you can specify terms and things in these queries as you improve your knowledge and understanding.

Read More  Application Modernization Isn’t Easy. But We Can Make It Easier.

4. How to Spot Problems Before They Affect Your Application

One of the benefits of Kubernetes is its ability to automatically return to a consistent state, but this can mask the effects of underlying problems for developers who do not know what to look for. For this reason, it is important that developers have access to Kubernetes logs and telemetry. Metrics like CPUs or memory used become even more important for Kubernetes-based applications because they can reveal issues with applications that Kubernetes may have masked. Surfacing problems before they affect customers is crucial to maintaining positive application experiences.

5. When to Investigate Problems

At its core, Kubernetes is about keeping applications running for production, so there is no direct output that explains why an app crashed or compels developers to take an active role in remediation. In most cases, Kubernetes just restarts the containers, and the problem is resolved. While it’s not an immediate issue as a result of the self-healing and resilient nature of Kubernetes and containers, it’s worth noting that this can mask or hide bad application behavior, which may cause it to go unnoticed for longer.

There are times when it is worth a deeper investigation into an issue, like if it’s affecting customer experience or causing negative downstream effects to other teams. The type of service being provided and the impact that performance issues have on customers can also come into play. For instance, requirements for applications supporting defense contractors will differ dramatically from those for a grocery app.

You Can Skip Deep Understanding of the Process

Although it’s essential for developers to understand how their applications run on Kubernetes, in most cases they don’t need a deep understanding of how Kubernetes works under the hood. As a developer, Kubernetes may seem like chaos to some degree, but you can control the chaos by providing specific directions to follow. For example, if you don’t specify where you want your pod to run, it will run anywhere that applications are allowed to run by default. Or, you can use taints/tolerations to tell Kubernetes not to run applications on specific nodes. However you configure (or don’t configure) this, you can use basic automated checks to show if the app is healthy.

Read More  Android Dev Summit 2019 | The Digital Wellbeing Opportunity

When getting started with Kubernetes, don’t overcomplicate it. Look at it as a way of managing your applications with a system that automatically takes action to repair itself and return to a healthy state with little intervention. The basics outlined in this post will provide a great starting point for developers to build a foundation and focus their education. As their knowledge and experience grows, they can expand their implementation of Kubernetes to be as specific and robust as needed.

 

Source: LogDNA by Ryan Staatz
This blog post was originally published on The New Stack on September 13, 2021. View the original here.


Our humans need coffee too! Your support is highly appreciated, thank you!

aster_cloud

Related Topics
  • Kubernetes
  • Kubernetes.io
  • LogDNA
You May Also Like
View Post
  • Architecture
  • Data
  • Engineering
  • People
  • Programming
  • Software Engineering
  • Technology

Predictions: Top 25 Careers Likely In High Demand In The Future

  • June 6, 2023
View Post
  • Architecture
  • Platforms
  • Software
  • Solutions
  • Technology

What To Expect From Apple’s WWDC 2023

  • June 1, 2023
View Post
  • Programming
  • Software Engineering
  • Technology

Build a Python App to Alert You When Asteroids Are Close to Earth

  • May 22, 2023
View Post
  • Multi-Cloud
  • Public Cloud
  • Software Engineering

Policy Controller Dashboard: Now Available For All Anthos And GKE Environments

  • May 18, 2023
View Post
  • Containers
  • Public Cloud
  • Software
  • Software Engineering

How To Easily Migrate Your Apps To Containers — Free Deep Dive And Workshop

  • May 18, 2023
View Post
  • Software
  • Technology

Somehow OpenSearch Has Succeeded

  • May 16, 2023
View Post
  • Public Cloud
  • Software

Best Practices For Monetizing Cloud-based Technology And 5G Networks

  • May 15, 2023
View Post
  • Public Cloud
  • Software

New Cloud Deploy Features Make Application Deployment Even More Efficient

  • May 15, 2023

Stay Connected!
LATEST
  • 1
    Predictions: Top 25 Careers Likely In High Demand In The Future
    • June 6, 2023
  • 2
    A S.W.O.T. Analysis Of Current A.I. Systems
    • June 6, 2023
  • Apple-WWCD23-Vision-Pro-glass-230605 3
    Introducing Apple Vision Pro: Apple’s first spatial compute
    • June 5, 2023
  • 4
    Apple Unveils New Mac Studio And Brings Apple Silicon To Mac Pro
    • June 5, 2023
  • 5
    Apple Introduces M2 Ultra
    • June 5, 2023
  • 6
    tvOS 17 Brings FaceTime And Video Conferencing To The Biggest Screen In The Home
    • June 5, 2023
  • 7
    Apple Introduces The 15‑Inch MacBook Air
    • June 5, 2023
  • 8
    Building A Kubernetes Platform: How And Why To Apply Governance And Policy
    • June 4, 2023
  • 9
    Leave, This “United” “Kingdom”, This “Great” “Britain”
    • June 4, 2023
  • 10
    Amazing Federated Multicloud Apps
    • June 2, 2023
about
Hello World!

We are aster.cloud. We’re created by programmers for programmers.

Our site aims to provide guides, programming tips, reviews, and interesting materials for tech people and those who want to learn in general.

We would like to hear from you.

If you have any feedback, enquiries, or sponsorship request, kindly reach out to us at:

[email protected]
Most Popular
  • 1
    Huawei ICT Competition 2022-2023 Global Final Held In Shenzhen — 146 Teams From 36 Countries And Regions Win Awards
    • May 27, 2023
  • 2
    Huawei OceanStor Pacific Scale-Out Storage Tops IO500 Rankings
    • May 26, 2023
  • 3
    What’s The Future Of DevOps? You Tell Us. Take The 2023 Accelerate State Of DevOps Survey
    • June 2, 2023
  • 4
    Resolving Deployment Issues With Ts-node And Azure Development Pipelines
    • June 1, 2023
  • 5
    MongoDB And Alibaba Cloud Extend Global Partnership
    • May 25, 2023
  • /
  • Technology
  • Tools
  • About
  • Contact Us

Input your search keywords and press Enter.