主页 | Web版 | 订阅 | 归档 | Feed

GopherDaily

20250828

每日一谚:Lead with context, end with options, and always close with an error


Go技术生态

我的Gopher“长期主义”:从《Go语言第一课》新书说起
四年前,我在极客时间开设了专栏《Go语言第一课》。令我欣慰的是,这个专栏得到了广大 Gopher 的认可和喜爱。截至今日,它已经影响了超 过 2.4 万名订阅者(截至2025.8),在编程语言类专栏里取得了相当不错的成绩。为了让这份经过市场检验的优质内容,能以一种更经典、更触手可及的方式,帮助更多人踏入 Go 语言的大门,我与人民邮电出版社异步图书合作, 历时一年多的精心打磨,终于将它变成了纸质书 -- 我的第二本“小黄书”

在并发Go应用程序中保持顺序:三种方法的比较
并发设计打破了固有的顺序,但有时我们需要两者兼顾。探索三种在并发Go应用程序中保持顺序的方法,从标准的ReplyTo通道到复杂的权限传递,并附有基准测试和实际的权衡。

Go Logging Best Practices: Fast, Structured, and Production-Ready
学习如何在 Go 中高效地进行日志记录,避免常见错误,并保持您的应用程序快速、干净并准备好投入生产。

Go Struct Alignment: A Practical Guide
Go structs are automatically aligned by the compiler for fast memory access. Understanding these rules helps reduce struct sizes, cut memory use, and avoid hidden performance pitfalls.

我们构建它,然后我们释放它:telemetry-harbor开源
我们正在开源遥测港口:我们在云端运行的相同高性能摄取堆栈,现在完全可自托管。基于 Go、TimescaleDB、Redis 和 Grafana 构建,它开箱即用,可用于生产。您的数据,您的规则,克隆,运行 docker compose,然后开始发送遥测数据。

Lago Manifesto:构建计费不应该令人头疼(对企业和工程师而言)
获得报酬应该是构建了人们想要的东西之后的简单部分。 这不是一个在社交媒体上疯传的问题,但在科技公司中却无处不在:定价和货币化需要很长时间才能发布(即使您设法发布了)。我们似乎认为事情就是这样。 多个全职工程师构建和维护计费系统?事情就是这样。 功能发布延迟,因为需要一个月的时间才能将新的定价电子表格转化为现实?事情就是这样。 即使您为计费软件付费,也需要内部构建所有内容?事情就是这样。 由于价格调整被 3 个边缘案例阻止,季度业绩没有达到预期?事情就是这样。 每天花费数小时手动开具发票和回答计费问题?事情就是这样。 一名工程师在他们的办公桌前哭泣,因为他们花了 2 天时间计算将购买的积分转换为使用额度的逻辑?事情就是这样。 您每周都必须支付夫妇的治疗师费用来参加工程团队和收入团队的同步会议?事情就是这样。 晚上 8 点,您正在修复发票格式以符合危地马拉法律的逻辑,梦想着回到更简单的时代,这样您就可以成为一名中世纪的铁匠,并以蒲式耳小麦获得报酬?事情就是这样。 事情就是这样,但它们不应该这样。 不久前,为地下室的服务器和飞往的技术人员升级 Oracle v2.483 到 Oracle v2.484 曾经是“事情就是这样”。 计费仍然处于地下室服务器时代。 它比以往任何时候都需要更新。 Lago 是那个更新——一种新型的货币化引擎。

云原生技术

A Beginner's Guide to Docker Swarm
This concludes our beginner-friendly series on Docker, Docker Compose, and Docker Swarm. We hope it has encouraged you to give these tools a try and sparked your curiosity to explore what else is possible.

Rust 重写与优化在 P99 CONF 25
P99 CONF 2025 将再次充满 Rust 元素。以下是我们将要展示的一些以 Rust 为主题的演讲的预览。

Docker Desktop 推出更快发布节奏,加速创新
Docker Desktop发布4.45.0版本,并将发布周期改为每两周发布一次,目标是在2025年底实现每周发布。这将使您可以更快地获得新功能、错误修复和安全更新。

Metal3.io 成为 CNCF 孵化项目
CNCF 技术监督委员会 (TOC) 已投票通过接受 Metal3.io 作为 CNCF 孵化项目。Metal3.io 加入了不断壮大的技术生态系统,致力于解决云原生基础设施边缘的现实世界挑战。

Kubernetes v1.34 Released
编辑:Agustina Barbetta, Alejandro Josue Leon Bellido, Graziano Casto, Melony Qin, Dipesh Rawat 与之前的版本类似,Kubernetes v1.34版本引入了新的稳定、beta 和 alpha 功能。高质量版本的持续交付凸显了我们开发周期的实力和我们社区的活力支持。 此版本包含 58 项增强功能。在这些增强功能中,23 项已升级为稳定版,22 项已进入 Beta 版,13 项已进入 Alpha 版。

Omarchy 2.0
Omarchy 2.0 在 Linux 的 34 岁生日之际发布,以此献给世界上最伟大的开源项目。 它不仅运行着网络上 95% 的服务器,数十亿设备的嵌入式操作系统,而且它也成为了一个令人难以置信的桌面环境! 很高兴能庆祝 Linux,我花了几个月的时间在 Arch 和 Hyprland 之上构建了新的 Linux 发行版 Omarchy。如果你有兴趣尝试 Linux,并且不怕一个让你不断提升和学习的操作系统, 那么我邀请你试试。

如何使程序变慢?以及为什么它可能有用。
使程序变慢可以用于查找竞争条件、模拟加速以及评估分析器的准确性。

Bluesky now platform of choice for science community
It’s not just you. Survey says: “Twitter sucks now and all the cool kids are moving to Bluesky”

Rust 带来的意想不到的生产力提升
Rust 以其陡峭的学习曲线而闻名,但在本文中,我们将关注另一条曲线,即开发者生产力与项目规模的关系。

OSHub上的面向对象设计模式
在OSDev的世界中,你通常是孤独的,这种孤独让你有自由去试验不寻常的编程模式。 我在为我的硕士论文开发一个内核模块时,偶然发现了一篇关于LWN的文章:“内核中的面向对象设计模式”。 文章描述了Linux内核,尽管是用C语言编写的,但通过使用结构体中的函数指针来实现多态性,从而采用了面向对象的原则。

关于容器和虚拟机
Incus 支持两种不同类型的实例:系统容器和虚拟机。 Incus 在系统容器的实现中使用 Linux 内核的特性(例如命名空间和 cgroups)。 这些特性提供了一种纯软件的方式来隔离和限制正在运行的系统容器。 系统容器只能基于 Linux 内核。

AI

构建你自己的 CLI 编码代理,使用 Pydantic-AI
CLI 编码代理是一种与聊天机器人或自动补全工具完全不同的工具——它们是可以读取代码、运行测试和更新代码库的代理。虽然商业工具令人印象深刻,但它们并不理解我们环境的特定上下文和我们特定项目的特殊性。相反,我们可以通过组装开源工具,使用我们特定的开发标准来构建我们自己的编码代理,用于:测试、文档生成、代码推理和文件系统操作。

流行工具与项目

hashicorp/terraform
Terraform enables you to safely and predictably create, change, and improve infrastructure. It is a source-available tool that codifies APIs into declarative configuration files that can be shared amongst team members, treated as code, edited, reviewed, and versioned.

googleapis/genai-toolbox
MCP Toolbox for Databases is an open source MCP server for databases.

spf13/cobra
A Commander for modern Go CLI interactions

cloudnative-pg/cloudnative-pg
CloudNativePG is a comprehensive platform designed to seamlessly manage PostgreSQL databases within Kubernetes environments, covering the entire operational lifecycle from initial deployment to ongoing maintenance

microsoft/typescript-go
Staging repo for development of native port of TypeScript

fatedier/frp
A fast reverse proxy to help you expose a local server behind a NAT or firewall to the internet.

opencontainers/runc
CLI tool for spawning and running containers according to the OCI specification

gohugoio/hugo
The world’s fastest framework for building websites.

envoyproxy/gateway
Manages Envoy Proxy as a Standalone or Kubernetes-based Application Gateway

0xJacky/nginx-ui
Yet another WebUI for Nginx

charmbracelet/lipgloss
Style definitions for nice terminal layouts 👄

stretchr/testify
A toolkit with common assertions and mocks that plays nicely with the standard library

traefik/traefik
The Cloud Native Application Proxy

kubernetes/kubernetes
Production-Grade Container Scheduling and Management

fleetdm/fleet
Open device management

actions/actions-runner-controller
Kubernetes controller for GitHub Actions self-hosted runners

usememos/memos
A modern, open-source, self-hosted knowledge management and note-taking platform designed for privacy-conscious users and organizations.

coroot/coroot
Coroot is an open-source observability and APM tool with AI-powered Root Cause Analysis. It combines metrics, logs, traces, continuous profiling, and SLO-based alerting with predefined dashboards and inspections.

prometheus/prometheus
The Prometheus monitoring system and time series database.

ollama/ollama
Get up and running with OpenAI gpt-oss, DeepSeek-R1, Gemma 3 and other models.

testcontainers/testcontainers-go
Testcontainers for Go is a Go package that makes it simple to create and clean up container-based dependencies for automated integration/smoke tests. The clean, easy-to-use API enables developers to programmatically define containers that should be run as part of a test and clean up those resources when the test is done.

nats-io/nats-server
High-Performance server for NATS.io, the cloud and edge native messaging system.

hashicorp/terraform-provider-aws
The AWS Provider enables Terraform to manage AWS resources.


编辑:Tony Bai

编辑主页:tonybai.com

GopherDaily项目:github.com/bigwhite/gopherdaily

Copyright 2019-2024 GopherDaily