The VictoriaMetrics Observability Blog
Read Our Technical & Business Content on Monitoring Solutions & Time Series Databases
Tag:

Go

Go sync.Mutex: Normal and Starvation Mode

by Phuong Le on Aug 9, 2024

Mutex in Go has two main flows: Lock and Unlock and 2 modes: Normal and Starvation Mode. The state field of mutex is a 32-bit integer that represents the current state, it’s divided into multiple bits that encode various pieces of information about the mutex.

Read

How Go Arrays Work and Get Tricky with For-Range

by Phuong Le on Aug 2, 2024

As always, we’ll start with the basics and then dig a bit deeper. Don’t worry, Go arrays get pretty interesting when you look at them from different angles. Arrays in Go are a lot like those in other programming languages. They’ve got a fixed size and store elements of the same type in contiguous memory locations.

Read

Golang Defer: From Basic To Traps

by Phuong Le on Jul 26, 2024

The defer statement actually has 3 types: open-coded defer, heap-allocated defer, and stack-allocated. Each one has different performance and different scenarios where they’re best used, which is good to know if you want to optimize performance.

Read

Vendoring, or go mod vendor: What Is It?

by Phuong Le on Jul 16, 2024

Vendoring is a different strategy as it keeps a copy of all your project’s dependencies directly within the project’s directory, rather than relying on an external cache.

Read

Performance optimization techniques in time series databases: sync.Pool for CPU-bound operations

by Roman Khavronenko / Aliaksandr Valialkin on Dec 8, 2023

This blog post is the fourth in the series of blog posts based on the talk about ‘Performance optimizations in Go’, GopherCon 2023. It is dedicated to various optimization techniques used in VictoriaMetrics for improving performance and resource usage.

Read

Performance optimization techniques in time series databases: Limiting concurrency

by Roman Khavronenko / Aliaksandr Valialkin on Nov 24, 2023

This blog post is a third in the series of the blog posts based on the talk about ‘Performance optimizations in Go’, GopherCon 2023. It is dedicated to various optimization techniques used in VictoriaMetrics for improving performance and resource usage.

Read

Performance optimization techniques in time series databases: function caching

by Roman Khavronenko / Aliaksandr Valialkin on Nov 17, 2023

This blog post is a second in the series of the blog posts based on the talk about ‘Performance optimizations in Go’, GopherCon 2023. It is dedicated to various optimization techniques used in VictoriaMetrics for improving performance and resource usage.

Read

Performance optimization techniques in time series databases: strings interning

by Roman Khavronenko / Aliaksandr Valialkin on Nov 7, 2023

This blog post is a first in the series of the blog posts based on the talk about ‘Performance optimizations in Go’, GopherCon 2023. It is dedicated to various optimization techniques used in VictoriaMetrics for improving performance and resource usage.

Read

Watch Your Monitoring SkyRocket With VictoriaMetrics!