<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Synchronization on Nalar</title>
    <link>https://nalar.dev/tags/synchronization/</link>
    <description>Recent content in Synchronization on Nalar</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Fri, 04 Sep 2026 00:00:00 +0700</lastBuildDate>
    <atom:link href="https://nalar.dev/tags/synchronization/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Coordinate Shared State with sync.Cond in Go</title>
      <link>https://nalar.dev/coordinate-shared-state-with-sync-cond-in-go/</link>
      <pubDate>Fri, 04 Sep 2026 00:00:00 +0700</pubDate>
      <guid>https://nalar.dev/coordinate-shared-state-with-sync-cond-in-go/</guid>
      <description>&lt;p&gt;A goroutine sometimes cannot make progress until shared state changes. A worker may need to wait until a queue contains an item. A producer may need to wait until that queue has free capacity. Several goroutines may need to sleep until a service becomes ready.&lt;/p&gt;&#xA;&lt;p&gt;Polling the state in a loop wastes CPU or forces you to invent arbitrary sleep intervals. Channels solve many coordination problems more directly, but they are not always a natural fit when several goroutines already share state protected by a mutex and need to wait for &lt;strong&gt;predicates&lt;/strong&gt; over that state.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
