Articles by Deepak Prasad
Operator Leader Election Explained: HA Operators with Lease Locks
A complete guide to running a multi-replica Kubernetes operator with leader election: how the lease-based lock works, the four manager options (`LeaderElection`, `LeaderElectionID`, `LeaderElectionResourceLock`, …
Operator Health and Readiness Probes: /healthz, /readyz, AddHealthzCheck
A practical guide to liveness and readiness probes for Kubernetes operators: what `/healthz` and `/readyz` should report, how to register custom checks with `mgr.AddHealthzCheck` and `mgr.AddReadyzCheck`, the difference …
Kubernetes Operator Watches, Events, and Predicates Explained
Learn how Kubernetes Operator watches, events, handlers, and predicates decide which changes trigger Reconcile, with Owns vs Watches examples.
Multi-Resource Reconciliation: Managing N Child Resources per CR
Most real operators do not manage one child — they manage five, ten, sometimes dozens of children per CR: a Deployment, a Service, two ConfigMaps, a HorizontalPodAutoscaler, a NetworkPolicy, a ServiceAccount, a …
Kubernetes Status Subresource and Conditions Explained (KEP-1623)
The status subresource is the API server endpoint controllers use to publish observed state without racing user edits on `.spec`. This guide explains why the split exists, the KEP-1623 Conditions standard (Ready / …
The Kubernetes Reconcile Loop Explained: From API Event to Reconcile()
Learn how the Kubernetes reconcile loop works from API watch to informer cache, workqueue, and Reconcile(). Covers level-triggered control, Result return paths, requeue behavior, idempotency, concurrency, and hot loop …
Kubernetes Operator Capability Levels I–V: The Operator Maturity Model
Red Hat's five operator capability levels - Basic Install, Seamless Upgrades, Full Lifecycle, Deep Insights, Auto Pilot - are the maturity scale used by OperatorHub and OLM. This guide explains what each level means, …
Kubernetes Operator Design Patterns: Singleton, Capability, Lifecycle, Auto-Pilot
Kubernetes Operators are not one shape - six distinct design patterns cover the entire range of production deployments: Singleton, Capability, Lifecycle, Auto-Pilot / Auto-Tune, Sidecar-Injecting, and GitOps-Controlled. …
Mutating and Validating Admission Webhooks in Operators
A complete guide to admission webhooks for Kubernetes operators: the difference between mutating and validating, the webhook lifecycle inside the API server, how kubebuilder scaffolds …
Kubernetes Finalizers: Two-Phase Deletion, Cleanup Patterns, and Stuck Objects
A Kubernetes finalizer is a string on `metadata.finalizers` that tells the API server to keep an object alive (with `deletionTimestamp` set) until your controller has finished cleanup and removed the string. This …
Helm-Based Operator vs Flux vs Argo CD: Which to Use
Three tools install Helm charts on a Kubernetes cluster: a Helm-based operator (per-CR Helm install), Flux's HelmRelease (HelmRelease CR + per-source reconciler), and Argo CD's Application (Application CR + sync engine). …
Drift Detection Patterns in Kubernetes Operators: Periodic Resync vs Spec Diffing
A Kubernetes operator detects drift in four layered ways: watch-based reconciliation, periodic resync with SyncPeriod, three-way spec diffing with client.Patch or Server-Side Apply, and external polling for resources …
Desired State vs Actual State in Kubernetes: The Level-Triggered Model
In Kubernetes, the desired state is what you declared in `.spec`, the actual state is what currently exists in the cluster, and the controller's job is to continuously reconcile the two. This guide explains why …
Helm Hybrid Operator Tutorial Part 1 of 2 - Build the Foundation (Go + Helm v4 SDK)
A Helm hybrid operator is a Go operator whose Reconcile calls the Helm SDK (v4) directly - the pre-built helm-operator, written by you, with full control. Part 1 of 2 walks the foundation: scaffold with operator-sdk init …
Helm-Based Operator Tutorial Part 1 - Build the Operator (Chart, CRD, watches.yaml)
A Helm-based operator wraps a Helm chart as a Kubernetes operator without you writing any Go code. The Operator SDK ships a generic reconciler that watches a CR, maps its `.spec` to Helm values, and runs `helm install` / …
Owner References and Garbage Collection in Kubernetes Operators
A complete guide to owner references and Kubernetes garbage collection for operators: the contract between an owner and its dependents, the difference between `SetControllerReference` and `SetOwnerReference`, three …
Install Operator-SDK on Linux: Complete Setup Guide (Go, kubectl, Helm 4, kind, ttl.sh registry)
A complete step-by-step guide to installing Operator-SDK on Linux (Ubuntu, RHEL, Fedora, Debian), including the prerequisite toolchain (Go 1.22+, kubectl, container runtime, Helm 4 CLI, kind), the three Operator-SDK …
Kubernetes Operator vs Controller vs CRD: What's the Difference?
A Custom Resource Definition (CRD) is the API contract, a Controller is the reconciler that watches and acts on it, and an Operator is the combination of a CRD plus a controller plus domain-specific knowledge about a …
What is a Kubernetes Operator?
A Kubernetes Operator is a custom controller paired with a Custom Resource Definition (CRD) that automates the day-2 operations of a complex application - install, upgrade, backup, failover, scaling - by continuously …
Parcel Management System Architecture (APIs, Database, Event-Driven Design)
Learn how to design a scalable parcel management system using APIs, database schema, event-driven architecture, queues, and cloud-native technologies like Kafka and Kubernetes.
Golang Read File (Line by Line, Entire File, Large Files Explained)
Learn how to read files in Golang using os.ReadFile, bufio.Scanner, and bufio.Reader. This guide covers reading entire files, line-by-line processing, handling large files efficiently, and common errors with practical …
Read File in Golang with Timeout (Handle Large Files, Scanner Errors & Real Examples)
Learn how to read files in Golang with timeout handling using select, time.After, and context.WithTimeout. This guide covers reading files line by line, in chunks, handling large files, fixing bufio.Scanner errors, and …
What Developers Should Know About the Hardware Their Code Runs On
Learn why understanding hardware fundamentals like CPU, memory, storage, and printed circuit boards is essential for developers to build high-performance, scalable, and reliable applications in modern computing …
Pytest Logging Explained (Set Log Level, Show Logs, caplog, Fix Issues)
Learn how to configure and use pytest logging effectively. This guide covers setting log levels, enabling live logs, using log_cli and caplog, fixing logs not showing, logging to file, and advanced configurations. …
Python Set add() Explained (Add Elements, Multiple Items, Common Mistakes)
Learn how to add elements to a set in Python using add() and update() methods. This guide covers adding single and multiple elements, handling duplicates, common mistakes like append() and insert(), and real-world use …
Python Compare Strings (==, Ignore Case, Substring, Examples)
Learn how to compare strings in Python with practical examples. This guide covers string equality, case-insensitive comparison, substring matching, lexicographic comparison, character-by-character comparison, and …
How to Rename File or Directory in Git (git mv Explained)
Learn how to rename a file or directory in Git using git mv and other methods. This guide covers renaming files, folders, and directories with practical examples, preserving history, handling case sensitivity issues, and …
Git Restore Explained with Examples (Files, Staged, Undo Changes)
Learn how to use git restore command with practical examples. Understand how to restore files, undo changes, unstage files using git restore --staged, and compare git restore vs reset vs checkout. Includes syntax, use …
How to Check CPU Usage in Linux (Top, htop, vmstat & More)
Learn how to check CPU usage in Linux using top, htop, vmstat, mpstat, sar, and ps commands. Monitor CPU utilization, load, and processes in real-time with practical examples.
How to Clear System Storage on Mac Using Terminal (Advanced Guide)
Learn how to clear system storage on Mac using terminal commands. This advanced guide covers disk usage analysis, cache cleanup, log removal, and troubleshooting system data taking excessive space on macOS.

