Engineering Blog

                            

Blog – 4 Column

A “Krispr” Approach to Kubernetes Infrastructure: Keeping Pods Fresh and Rolling Out Updates Smoothly

Introduction In the demanding world of modern service-oriented architectures, maintaining fresh and up-to-date infrastructure is crucial for optimal performance and security. Airbnb, with its hundreds of services relying on Kubernetes, faced challenges in efficiently updating shared infrastructure components within their platform. Their existing approach, heavily dependent on service owner upgrades, led to version fragmentation, complexity,…

Get ready for KubeCon + CloudNativeCon Europe –Cloud Innovation
Get ready for KubeCon + CloudNativeCon Europe –Cloud Innovation

The  KubeCon + CloudNativeCon Europe event is just around the corner! This is your chance to dive into the world of Kubernetes and cloud-native technologies, meet industry experts, and connect with fellow enthusiasts. Important Reminder: Reserve your spot now to lock in the current rates and save before prices go up! Don’t miss out on this…

Scaling Kubernetes to 2,500 Nodes for Deep Learning at OpenAI
Scaling Kubernetes to 2,500 Nodes for Deep Learning at OpenAI

OpenAI, a pioneer in artificial intelligence, pushes the boundaries of Kubernetes by scaling it to manage massive deep learning workloads. While managing bare VMs remains an option for the largest tasks, Kubernetes shines for its rapid iteration cycles, reasonable scalability, and reduced development overhead. This blog dives into OpenAI’s journey building a 2,500-node Kubernetes cluster…

Overusing getters and setters
Overusing getters and setters

Encapsulation is used to hide the values or state of a structured data object, preventing unauthorized parties’ direct access to them. In Golang there is no by default support of getters and setters, so it is optional. There are few advantage of using getters and setters event in golang and they are mentaion below :-…

Avoid any Type in TS (anti-pattern)
Avoid any Type in TS (anti-pattern)

What are types in TS? Types in TS helps us understand what methods & properties are associated with a given value/variable in a program that can help us analyze our code for existing errors and prevent further errors. For example a value that is assigned a type of a string tells us that the value…

Variable Shadowing in Go

As a part of this blog post, I will try to explain about variable shadowing and how to avoid it. In programming, scope of variable defines to the places a variable can be referenced. In Golang, a variable name declared in a block can be redeclared in an inner block. This mechanism is called variable shadowing….

Interface on producer side

Interfaces are used to create common abstractions that multiple objects can implement. Before delving into this topic, let’s make sure the terms we use throughout this section are clear: It’s common to see developers creating interfaces on the producer side, alongside the concrete implementation. But in Go, in most cases, this is not what we…

Unnecessary nested code

Readable code requires less cognitive effort to maintain a mental model; hence, it is easier to read and maintain. A critical aspect of readability is the number of nested levels. Code is qualified as readable based on multiple criteria such as naming, consistency, formatting, and so forth. While programming, we need to maintain mental models…

Misuse of Init Function in Golang

What is init function? An init function is a function used to initialize the state of an application. It takes no arguments and returns no result( a func() function). When a package is initialized, all the constant and variable declarations in the package are evaluated. Then, the init functions are executed. Init Function Example Misuse…

Interface Pollution in Golang

Interfaces are one of the cornerstones of the Go language when designing and structuring our code. However, like many tools or concepts, abusing them is generally not a good idea. Interface pollution is about overwhelming our code with unnecessary abstractions, making it harder to understand. So, first we understand the concept of interface and then…

Not being aware of the possible problem of type embedding

Concept of embedded field A struct field without a name is known as embedded field. For example :- In the Employee struct, the Address type is declared without an associated name; hence, it’s an embedded field. But this can sometimes lead to unexpected behaviors if we don’t understand all the implications of type embedding. Note…

Being confused about when to use generics

Introduction The Go 1.18 release introduced a new feature called generic types (commonly known by the shorter term, generics). This allows writing code with types that can be specified later and instantiated when needed. However, it can be confusing about when to use generics and when not to. In this blog, I will try to describe the concept…