<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Sync on 编程心语</title>
		<link>https://www.ithome.me/tags/sync/</link>
		<description>Recent content in Sync on 编程心语</description>
		<generator>Hugo</generator>
		<language>zh-CN</language>
		
		
		
		
			<lastBuildDate>Tue, 21 Jul 2026 08:33:03 +0800</lastBuildDate>
		
			<atom:link href="https://www.ithome.me/tags/sync/index.xml" rel="self" type="application/rss+xml" />
			<item>
				<title>Go 并发原语实战：sync.Pool、sync.Once 与 sync.Cond 的正确打开方式</title>
				<link>https://www.ithome.me/post/2026/07/21/go-sync-primitives-pool-once-cond/</link>
				<pubDate>Tue, 21 Jul 2026 08:00:00 +0800</pubDate>
				<guid>https://www.ithome.me/post/2026/07/21/go-sync-primitives-pool-once-cond/</guid>
				<description>&lt;p&gt;Go 的并发编程有两套武器库：一套是 CSP 模型的 goroutine + channel，另一套是标准库 &lt;code&gt;sync&lt;/code&gt; 包提供的底层原语。大多数教程把焦点放在 channel 上，但真正到生产环境里，&lt;code&gt;sync.Pool&lt;/code&gt;、&lt;code&gt;sync.Once&lt;/code&gt; 和 &lt;code&gt;sync.Cond&lt;/code&gt; 这三个原语用得反而不少——它们各自解决 channel 不擅长的问题。本文用实际代码逐一拆解。&lt;/p&gt;</description>
			</item>
	</channel>
</rss>
