<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Concurrency on Lorbic</title><link>http://localhost:1313/tags/concurrency/</link><description>Recent content in Concurrency on Lorbic</description><generator>Hugo</generator><language>en</language><lastBuildDate>Thu, 13 Aug 2026 18:00:00 +0530</lastBuildDate><atom:link href="http://localhost:1313/tags/concurrency/index.xml" rel="self" type="application/rss+xml"/><item><title>How Go Channels Actually Work</title><link>http://localhost:1313/go-channels-deep-dive/</link><pubDate>Thu, 13 Aug 2026 18:00:00 +0530</pubDate><guid>http://localhost:1313/go-channels-deep-dive/</guid><description>&lt;p>A single unbuffered channel send without an active receiver is enough to silently lock up a production worker pool, leaking memory until your service gets killed by the OS kernel.&lt;/p>
&lt;p>On the surface, Go channels look simple: they synchronize concurrent execution without manual mutex management. But under heavy load, a minor oversight in channel sizing or worker coordination blocks the scheduler, leaks memory, or crashes processes with runtime panics.&lt;/p>
&lt;p>&lt;picture class="optimized-image-container">&lt;source srcset="http://localhost:1313/go-channels-deep-dive/go-scheduler-meme_hu_524f15f4ab89fd6f.webp 480w, http://localhost:1313/go-channels-deep-dive/go-scheduler-meme_hu_50f95d885458376d.webp 646w" sizes="(max-width: 800px) 100vw, 800px" type="image/webp">&lt;img src="http://localhost:1313/go-channels-deep-dive/go-scheduler-meme_hu_50f95d885458376d.webp" width="646" height="797" alt="The Go scheduler coordinating 10,000 goroutines on a single-core CPU" loading="eager" decoding="async" fetchpriority="high" class="img-fluid" />
 &lt;/picture>&lt;/p></description></item><item><title>Constructing Concurrent Inverted Indexes in Go</title><link>http://localhost:1313/constructing-concurrent-inverted-indexes-in-go/</link><pubDate>Tue, 16 Jun 2026 22:00:00 +0530</pubDate><guid>http://localhost:1313/constructing-concurrent-inverted-indexes-in-go/</guid><description>&lt;p>I spent a Saturday afternoon benchmarking a concurrent inverted index and discovered that a single &lt;code>sync.RWMutex&lt;/code> starts to break down at roughly 4 concurrent readers. The degradation is not linear. It is not graceful. It is a cliff.&lt;/p>
&lt;p>The inverted index is one of the oldest data structures in information retrieval. It maps terms to the documents that contain them, forming the backbone of every search engine from Elasticsearch to Lucene to Google&amp;rsquo;s earliest prototypes. The data structure itself is simple. Making it fast under concurrent load is not.&lt;/p></description></item><item><title>Why Your Goroutines Need a Speed Limit: Bounded Concurrency in Go</title><link>http://localhost:1313/bounded-concurrency-in-go/</link><pubDate>Fri, 10 Apr 2026 10:00:00 +0530</pubDate><guid>http://localhost:1313/bounded-concurrency-in-go/</guid><description>&lt;p>&lt;strong>TL;DR:&lt;/strong> Spawning &lt;code>go func()&lt;/code> without a limiter is a recipe for system collapse. This guide details how to use &lt;strong>Semaphores&lt;/strong> and &lt;strong>Worker Pools&lt;/strong> to prioritize predictable stability over absolute speed, protecting downstream dependencies from the thundering herd.&lt;/p>
&lt;hr>
&lt;p>It&amp;rsquo;s a rite of passage for every Go developer. You receive a list of 10,000 URLs to fetch or 50,000 rows to process. You wrap the workload in an unbounded &lt;code>go func()&lt;/code> loop, achieving maximum throughput in milliseconds.&lt;/p></description></item></channel></rss>