Understanding Polymorphism and Key Differences Between Go and Java
Polymorphism in Go
Polymorphism in object-oriented programming refers to the ability of an object to take on many forms. In Go, polymorphism is achieved through interfaces:
type SoundMaker interface {
MakeSound()
}
func ProduceSound(s SoundMaker) {
s.MakeSound()
}
Go vs Java Comparison
Language Fundamentals
Feature
Go
Java
Typi ...
Posted on Mon, 03 Aug 2026 16:04:19 +0000 by mitjakac
Understanding Go Arrays and Slices: Key Differences and Usage Patterns
Arrays in Go
An array in Go is a fixed-size collection of elements of the same type. Unlike other programming languages, Go arrays have a fixed length that cannot be modified after declaration.
Array Declaration and Basic Operations
Arrays are declared using the following syntax:
var variable_name [size]data_type
var numbers [5]int
numbers[0] ...
Posted on Thu, 30 Jul 2026 16:53:57 +0000 by pomme
Inside the Kubernetes Job Controller: Controller Setup and Event Handlers
Entry Point
The Job controller lives in pkg/controller/job/job_controller.go. NewController() builds the controller instance, and its Run() method starts the sync loops. Higher up, the controller manager wires it like this:
cmd/kube-controller-manager/app/batch.go:34
func startJobController(ctx context.Context, controllerContext ControllerCon ...
Posted on Fri, 24 Jul 2026 16:34:42 +0000 by anolan13
Go Language Reflection Fundamentals and Core Principles
Understanding Reflection in Go
Reflection is a powerful mechanism that enables programs to examine and manipulate the internal properties of objects of arbitrary types during runtime. In Go, the built-in reflect package provides capabilities for dynamic type and value manipulation, allowing developers to inspect variable types, struct fields, i ...
Posted on Thu, 23 Jul 2026 16:23:33 +0000 by Pascal P.
Comprehensive PHP and Go Interview Questions from Major Tech Companies
Echo Technology First Round
Kafka Multiple Partitions Ensuring Message Order
Initially sending messages can be achieved by specifying key + single partition
When multiple consumers process data, you can take modulo of the key and place it into queues, then use multiple threads to consume these queues. Queues maintain internal order
MySQL W ...
Posted on Sun, 12 Jul 2026 17:26:35 +0000 by Topper
Building a Custom Kubernetes Scheduler for Database Workloads
Customizing the Kubernetes scheduling logic follows a similar pattern to writing MySQL UDFs or Hive custom functions; it requires adhering to specific interfaces and extension points defined by the platform.
Background
The goal is to implement scheduling capabilities for database services running on Kubernetes. Standard K8s scheduling focuses p ...
Posted on Sun, 12 Jul 2026 16:48:04 +0000 by ghadacr
Graph Algorithms for Island Problems in Go
Water Flow Simulation
Siumlate water flow using two visited matriecs for tracking.
Depth-First Search Implementation
package main
import "fmt"
var dirs = [][]int{{1, 0}, {-1, 0}, {0, 1}, {0, -1}}
func main() {
var rows, cols int
fmt.Scanln(&rows, &cols)
grid := make([][]int, rows)
vis1 := make([][]bool, ...
Posted on Thu, 09 Jul 2026 16:35:05 +0000 by Pryach
Understanding Maps in Go Programming Language
Map Declaration
Maps in Go are similar to dictionaries in Python. To declare a map, use the following syntax:
var mapVariable map[keyType]valueType
In this declaration:
keyType defines the data type of keys
valueType defines the data type of corresponding values
By default, map variables are initialized to nil. Memory allocation requires the ...
Posted on Mon, 06 Jul 2026 17:16:05 +0000 by javamint
Underlying Memory Mechanisms in Go Development
Effective memory utilization within the Go runtime relies heavily on underlying operating system mechanisms. The language design leverages OS capabilities to maximize performance while minimizing overhead, making it essential to understand how hardware and kernels manage addressable space.
Operating System Memory Models
Modern memory management ...
Posted on Sun, 05 Jul 2026 17:06:31 +0000 by zonkd
Implementing Task Queues in Go Using Goroutines and Channels
Go excels at building asynchronous systems through lightweight goroutines and channels, offering simpler constructs than many languages' async/await models. Below are practical patterns for implementing task queues.
Direct Asynchronous Execution
For trivial cases, firing off a task asynchronously requires no queue:
go handleTask(item)
This suf ...
Posted on Sat, 04 Jul 2026 17:32:35 +0000 by Lee