💻 Programming and Technology Blog:

Zero Allocation in Java: what it is and why it matters Zero Allocation — is an approach to writing code in which no unnecessary objects are created in heap memory during runtime. The main idea: fewer objects → less GC → higher stability and performance. ⚡ 1. Simple explanation Every time an object is created in Java: memory is allocated in the heap ...
Stream vs For in Java: how to write the fastest code possible In Java, performance is often determined not by the "beauty of the code," but by how it interacts with memory, the JIT compiler, and CPU cache. Let s analyze why the usual for is often faster than Stream, and how to write truly fast code. 1. Basic truth: Stream vs For — this is not an equal battle ...
Compiler, Build, and Tooling in Go and Java: how assembly, initialization, analysis, and diagnostics are organized in two ecosystems This article is dedicated to a general overview of how the compiler, build, and tooling practices are arranged in Go, and how to better understand them through comparison with Java. We will not delve into the specialized details of each individual command or the internal workings of the compiler, bu...
Low-level mechanisms - part 2 | Go ↔ Java In this article, we gathered the key low-level mechanisms of Go that most often raise questions for developers coming from Java. We will consider: unsafe.Pointer, struct alignment, pointer arithmetic, zero-copy, iota, the internals of interfaces, runtime.SetFinalizer, and runtime.KeepAlive. We wil...
Go ↔ Java: Complete Guide to Runtime, Memory, and Allocator - Part 3 This article is a comprehensive guide to the key aspects of memory and runtime work in Go and Java. We will discuss fundamental concepts: execution scheduler, memory barriers, memory alignment, stack growth, fragmentation, allocation hot spots, and the internal architecture of the Go allocator. Th...
Low-level mechanisms | Go ↔ Java In this article, we will examine the key low-level mechanisms of Go, comparing them to similar tools in Java. The article is intended for Java developers who want to gain a deeper understanding of Go, as well as for Go developers, who wish to see how their familiar mechanisms are structured in Java....
Scheduler internals in Go ↔ Java: how your code is actually executed When you write go func() or create a Thread in Java, it seems like you are managing concurrency. But in reality, you are passing the task to the scheduler. And this is where the real show begins. Go and Java use fundamentally different models: Go — M:N scheduler (many goroutines on fewer threads),...
Slice internals in Go ↔ Java: from header to hidden allocations Slice in Go is one of those structures that looks simple, but under the hood behaves like a little clever beast. If you are a Java developer, you might think: "well, this is just an ArrayList." And this is where the magic begins — it’s not quite so. In this article, we will discuss: how the slice ...
Map internals from random order to bucket evacuation | Go ↔ Java In this article, we will examine the internal structure of maps / hash tables in Go and Java. If you are a Java developer used to HashMap, you will be interested in how differently Go thinks. If you are a gopher — you will see why such compromises are made in Java. We will cover key aspects: random ...
Internal structure of the Garbage Collector: Go ↔ Java In this article, we will thoroughly examine the work of the garbage collector (Garbage Collector, GC) in Go and Java, discuss key internal mechanisms: concurrent mark & sweep, mutator vs collector, tricolor marking, GC pacing, root set scanning, and stack scanning. For Java developers, this will...
Memory, Runtime, and Allocator: A Comparison of Go and Java for Developers In this article, we will examine the key aspects of memory management, runtime, and object allocation mechanisms in Go and Java. We will focus on the differences in approaches to memory management, working with the stack and heap, and how these mechanisms affect performance, safety, and ease of deve...
Atomic vs Mutex, Blocking vs Non-Blocking, Read/Write Splitting (RWMutex), Logging | Concurrency Patterns and Best Practices part 5 | Go ↔ Java In this article, we will analyze the key approaches to working with parallelism and synchronization in Go and Java. We will compare how the same tasks are solved in these languages, show idioms, patterns, and best practices. The material will be useful for both Java developers learning Go and Go dev...
Resource cleanup, rate-limiting strategies, bounded vs unbounded channels - in Go vs Java | Patterns, idioms, and best practices for Go We continue the series of articles for developers who want to learn Go based on knowledge of Java, and vice versa. In this article, we will discuss three key topics: Resource Cleanup (resource release), Rate-Limiting Strategies (load limiting strategies) and Bounded vs Unbounded Channels (bounded an...
Breaking down: Rate-limiter, non-blocking operations, scheduler Go vs Java | Concurrency part 4 This article is dedicated to understanding the principles of working with concurrency and synchronization in Go and Java. We will look at key approaches such as rate-limiter, non-blocking operations, and task scheduling, compare their implementation and philosophy in both languages. This will help a...
Let's look at: Trace, Profiling, Integration Testing, Code Coverage, Mocking, Deadlock Detection in Go vs Java | Testing, Debugging and Profiling Series: Go for Java Developers — analysis of trace, profiling and testing In this article we will analyze tools and practices for testing, debugging and profiling in Go. For a Java developer this will make it easy to navigate in Go, and for a Go developer — to compare approaches with Java. Trace ...
Generics, Reflection and Channels - Go vs Java | Types - Language In this article we will analyze advanced type system features in Go: generics (type parameters), reflection, and channel types for concurrency. We will compare Go and Java approaches, so Java developers can more easily learn Go, and experienced Go developers — understand how these concepts are imple...
Pointers, functions, and execution control in Go vs Java | Types - Language Series: Go for Java Developers — analyzing pointer, closures, defer, panic/recover In this article, we will analyze how Go manages the state and lifecycle of functions. A feature of Go is the ease of working with pointers without complex arithmetic, powerful closures, and built-in mechanisms for sa...
Struct, methods and interfaces in Go vs Java | Types - Language Series: Go for Java Developers — exploring struct, interface, receiver types and type embedding In this article, we will examine how types architecture is built in Go. For a Java developer, this is especially important, as Go does not use classes in the conventional sense, and types and methods are...
Analyzing: array, slice, map, zero value - in Go vs Java | Types - Language Series: Go for Java Developers This article opens a series of materials about the Go language for developers who are already well acquainted with Java. We will compare the approaches of the two languages to quickly understand how the Go data model is structured and why it looks the way it does. Wh...
Analysis of Unit testing, Race detector, Benchmarking, Profiling (pprof) Go vs Java | Testing, Debugging, and Profiling 1. Unit testing In Go, the built-in package testing allows writing unit tests. For Java developers, this is analogous to JUnit/TestNG. Unit tests in Go are simple and built into the standard library. For Java, it is more common to use JUnit or TestNG. 2. Race detector Go has a built-in -race ...
By sending an email, you agree to the terms of the privacy policy

Useful Articles:

Atomic vs Mutex, Blocking vs Non-Blocking, Read/Write Splitting (RWMutex), Logging | Concurrency Patterns and Best Practices part 5 | Go ↔ Java
In this article, we will analyze the key approaches to working with parallelism and synchronization in Go and Java. We will compare how the same tasks are solved in these languages, show idioms, patte...
How to keep a legacy project from dying and give it another 10 years
Signs of a legacy project: how to recognize an old ship A legacy is not just old code. It is a living organism that has survived dozens of changes, team shifts, outdated technologies, and numerous tem...
Java under the Microscope: Stack, Heap, and GC using Code Examples
Diagram - Java Memory Model - Heap / Non-Heap / Stack Heap (memory for objects) Creates objects via new. Young Generation: Eden + Survivor. Old Generation: objects that have survived several GC c...

New Articles:

Zero Allocation in Java: what it is and why it matters
Zero Allocation — is an approach to writing code in which no unnecessary objects are created in heap memory during runtime. The main idea: fewer objects → less GC → higher stability and performance. ...
Stream vs For in Java: how to write the fastest code possible
In Java, performance is often determined not by the "beauty of the code," but by how it interacts with memory, the JIT compiler, and CPU cache. Let s analyze why the usual for is often faster than Str...
Compiler, Build, and Tooling in Go and Java: how assembly, initialization, analysis, and diagnostics are organized in two ecosystems
This article is dedicated to a general overview of how the compiler, build, and tooling practices are arranged in Go, and how to better understand them through comparison with Java. We will not delve ...