#510 — June 11, 2024 |
|
Go Weekly |
An Applied Introduction to eBPF with Go — eBPF is a technology that allows running sandboxed programs within the Linux kernel, enabling a wide range of advanced networking, security, and observability capabilities. This post covers two examples of using eBPF to monitor system calls and incoming IP packets. Ozan Sazak |
Build Go Apps That Scale on AWS — Learn how to build and deploy scalable applications to AWS using Go. This detailed video course will cover AWS Lambda, DynamoDB, API Gateway, JSON Web Tokens, and more. Frontend Masters sponsor |
The Profile-Guided Optimization Experience at Grab — First, Dolt showed us their wins using Go 1.21+’s profile-guided optimization (PGO) feature. Then Cloudflare needed 97 fewer CPU cores thanks to it. Now, folks working on Southeast Asia’s leading ‘superapp’, Grab, show off their wins and learnings, along with the Dockerfile used to make it happen. Hu and Sharma (Grab) |
QUICK BITS:
|
Go Error Propagation and API Contracts — Not another rant about error verbosity in Go, but an example-driven plea to be more intentional with handling errors returned from other functions your code calls. Luckily, you have several options, but any choice should be intentional and apropos. Matt T. Proud |
Error Flows in Go — Sticking to the theme of errors! Last year, Preslav wrote Go’s Error Handling is a Form of Storytelling – here’s the followup, where he stresses the importance of fleshing out the context of what caused an error, since “X failed” is often no help at all. Preslav Rachev |
Sentinel Errors and Zach Musgrave (DoltHub) |
Hookdeck: The AWS API Gateway + Amazon EventBridge Alternative — Receive, authenticate, transform, filter, route, & send events across your EDA with an event gateway for engineering teams. Hookdeck sponsor |
How to Build and Deploy a Telegram Bot with Kamal — The bot is written in Go, but deployed using Kamal, a container based deployment tool fresh from the Ruby world. Kyrylo Silin |
📄 Things You Wish You Didn't Need to Know About S3 Daniel Grzelak 📺 Creating a Distributed File Storage System in Go Anthony GG |
🛠 Code & Tools |
Gowebly: A CLI to Build Web Apps with Go — Put together the fundamentals of a basic full-stack webapp quickly with this. Supports Go frameworks like Fiber, Gin, and Echo, but also brings things like htmx, Hyperscript, Tailwind CSS, and Alpine.js into play. Live reloading, too! GitHub repo. Gowebly |
Announcing GoReleaser v2 — A tool for releasing Go projects with cross-compilation, releasing to systems like GitHub and GitLab, nightly builds, image creation, etc. v2 removes lots of deprecated features so you need to take care when upgrading – GitHub repo. Carlos Becker |
xstrings: String Functions Used in Other Languages But Absent in Go — Lots to enjoy here, such as ‘centering’ strings, changing between different casing systems, partitioning strings, counting words, reversal, etc. Huan Du |
|
Stateless: A Fluent Library for Creating State Machines — It supports almost the same API as a similar project in C#. Quim Muntal |
Tokenizer: Pure Go Implementation of OpenAI's Tokenizer — When you use OpenAI’s GPT, input and output is delivered in ‘tokens’ which are not the same as characters, syllables or words, but somewhere in between. Wahlmann and Wendt |
|