Golang Digest
2.53K subscribers
164 photos
1 video
190 links
Everything about Go: news, articles, tools, language changes, etc.

#go #golang #concurrency #postgres #database #db
Download Telegram
Channel created
βœ… Speed up your app with optimizations in Go 1.20

In Go 1.20, new PGO optimizations were added. These compiler optimizations use profiles from pprof to speed up applications and reduce resource usage by up to 14%. Check out this link for Cloudflare's experience with this tool and how they improved performance and saved on infrastructure costs.

Link to the article

#go #optimization #article
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘1
βœ… River - fast and reliable background tasks in Go

The library allows for easy and simple setup of task queues: create a structure, write a Work() method where you describe what the task will do, and launch the server. Then, from anywhere in your program, you can send new tasks that will be executed in the background right away.

Library link

#go #library
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘2❀1
βœ… The Go Blog - Robust generic functions on slices

In the article, the language's authors tell you what improvements they added to the "slices" package in Go 1.22, and why these changes can save you from unobvious memory leaks.
Slice is one of the most important and frequently used data types, so how they are structured is important.

Link to the article

#go #generics #article
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘2
βœ… The Complete NeoVim Configuration Guide for Developers

A large and detailed manual on how to configure neovim for development for any programming language, using Golang as an example.

Link to the article

#go #vim #nvim #tools #channel_team_article
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘2
βœ… Making a Postgres query 1,000 times faster

The Mattermost article explains how they sped up a Postgres query used for Elasticsearch indexing. The initial query was slow due to inefficient data filtering. By optimizing with row constructor comparisons, they improved performance by 1000 times, significantly reducing query execution time.

Link to the article

#postgres #db
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯4πŸ‘1
βœ… How I write HTTP services in Go after 13 years

Mat Ryer works at grafana and talks about what Go development patterns he has come to over 13 years of work and describes many subtleties that can only be achieved with extensive experience.

Link to the article

#go #article
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘2
βœ… Generic Concurrency in Go

An excellent article from Sergey Kamardin, β€œGeneric Concurrency in Go,” where the author discusses how to use generics to create efficient parallel processing patterns in Go. The article also covers handling context cancellation, limiting concurrency, reusing goroutines, and generalizing the approach to working with different data types and structures.

Link to the article

#go #article
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯4❀1πŸ‘1
βœ… Boost performance of Go applications with profile guided optimization

In a previous post, we discussed how the Cloudflare team used profile-based optimization (PGO) to improve their applications. PGO allows the compiler to optimize code based on real-world profiler data, resulting in more efficient and performant applications.

In this talk, we'll dive deeper into how PGO works under the hood.

Link to the video

#go #video
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘3πŸ”₯2❀1
βœ… Go Enums Suck: let's make them suck less

The article "Go Enums Suck" discusses the lack of native support for enums in Go and provides a method to implement them using the iota keyword. It highlights the limitations of this approach and offers a comprehensive solution to create more robust and type-safe enums. The author then introduces a tool called goenums, which generates Go code for enums based on a JSON configuration, making the implementation process easier and more consistent.

Link to the article

#go #article
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘2