<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/bluesky-s-goroutine-death-spiral-two-go-compiler-memory-safety-bugs-rmlykild4" -->

---
title: Bluesky&#x27;s goroutine death spiral, two Go compiler memory...
description: A Go-focused roundup covering four major stories: Bluesky&#x27;s post-mortem on an 8-hour outage caused by unbounded goroutine concurrency exhausting TCP ports and...
canonical: https://daily.dev/posts/bluesky-s-goroutine-death-spiral-two-go-compiler-memory-safety-bugs-rmlykild4
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Bluesky&#x27;s goroutine death spiral, two Go compiler memory safety bugs | daily.dev
og:description: A Go-focused roundup covering four major stories: Bluesky&#x27;s post-mortem on an 8-hour outage caused by unbounded goroutine concurrency exhausting TCP ports and...
og:url: https://daily.dev/posts/bluesky-s-goroutine-death-spiral-two-go-compiler-memory-safety-bugs-rmlykild4
og:image: https://api.daily.dev/og/posts/rmlykIlD4.png
og:image:alt: Bluesky&#x27;s goroutine death spiral, two Go compiler memory safety bugs
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Bluesky's goroutine death spiral, two Go compiler memory safety bugs

**[Go Digest](https://daily.dev/sources/golang_digest)** · 5 min read · 3 upvotes · 0 comments

## Summary

A Go-focused roundup covering four major stories: Bluesky's post-mortem on an 8-hour outage caused by unbounded goroutine concurrency exhausting TCP ports and cascading into OOMs (fixed with a single errgroup.SetLimit call); two Go compiler bugs up to v1.26.1 that break memory safety guarantees using only safe code via flawed optimization passes; the constmap library offering 3x faster and 6x more memory-efficient immutable string map lookups using binary fuse filters; and Google's Agent Development Kit for Go reaching v1.0 with OpenTelemetry and self-healing support. Also covered: the Solod Go-to-C11 transpiler, Bloom filters in production at 18k req/s, TinyGo supporting 100+ boards, and several other Go ecosystem projects.

## Content

**TLDR:** Bluesky published a detailed post-mortem on an 8-hour outage caused by unbounded goroutine concurrency exhausting TCP ports and cascading into OOMs. Separately, a security researcher found two compiler bugs in Go up to 1.26.1 that break memory safety guarantees using only safe code. On the tooling side, Google's Agent Development Kit for Go hit v1.0, and constmap landed with 3x faster lookups than the built-in map.

---

## Bluesky's April outage: missing `errgroup.SetLimit` took down 50% of users for 8 hours

A single missing concurrency limit in a `GetPostRecord` RPC handler let batches of 15-20k URIs spawn tens of thousands of goroutines simultaneously. That exhausted ephemeral TCP ports via memcached connection churn, which triggered millions of log writes per second, which caused the Go runtime to spawn roughly 10x more OS threads, which stressed the GC into long stop-the-world pauses, which combined with aggressive `GOGC`/`GOMEMLIMIT` settings to cause OOMs. On restart, TIME_WAIT sockets blocked new memcached connections and the whole cycle repeated. The band-aid was a custom dialer that randomized the loopback source IP across the full `127.0.0.0/8` range to expand the available port space. The real fix was one line: `errgroup.SetLimit`. The lessons are worth reading — bound goroutine concurrency in every batch endpoint, prefer Prometheus/OTEL over high-volume logging, and add per-client observability before you need it.

## Two Go compiler bugs break memory safety without `unsafe`

A security researcher found and reported two bugs in Go up to 1.26.1 that produce memory corruption using only safe Go code. The first is in the `prove`/`loopbce` optimization pass, which incorrectly reasons about signed integer wrap in induction variables and eliminates bounds checks when the index can actually go negative. The second is in SSA lowering, where a no-op type conversion causes the compiler to skip the safe overlapping-copy path. Both share the same root cause: the compiler promoting "probably safe" to "proved safe" prematurely. The researcher calls this "counterfeit certainty" — and in a twist, git blame showed they had introduced the underlying code for the first bug themselves three years earlier. The takeaway is blunt: memory safety is a property of the whole toolchain, not just the language spec.

## constmap: immutable string maps with 3x faster lookups and 6x less memory

constmap is a new Go library for immutable string-to-uint64 maps using the binary fuse filter algorithm. Lookups cost one hash computation, three array accesses, and two XOR operations — benchmarks show 7.6 ns/op versus 23 ns/op for the built-in map, and 9 bytes per key versus 56. There's a `VerifiedConstMap` variant that detects missing keys at the cost of doubled memory. It supports serialization with FNV-1a checksum validation. The obvious constraint is that the map is immutable after construction, so it fits a specific set of use cases — config lookups, routing tables, static datasets — but for those it's a meaningful improvement.

## Google's ADK for Go hits v1.0

Google's Agent Development Kit for Go reached v1.0 this week, shipping with OpenTelemetry integration, self-healing logic, and safety guardrails. A demo walkthrough showed a sailing trip planner built with it: parallel agents combining deterministic API calls (weather, tides, sunrise math) with AI sub-agents for localized content. One architectural note worth flagging — the Google Search tool had to be isolated into a sub-agent due to a known ADK/Gemini incompatibility. A Temporal integration for durability and automatic retries is apparently coming.

---

## Also notable

- **Solod transpiler:** Converts a strict subset of Go to readable C11 with zero runtime, no GC, and no CGO — goroutines, closures, and generics are excluded, but structs, interfaces, slices, and defer are supported.
- **Bloom filters in production:** A case study on using Go Bloom filters in a recommender service at 18k req/s showed p95 latency drop from ~140ms to ~96ms and backend read traffic down ~65-70%.
- **Let's Encrypt's certificate test infrastructure:** Built in Go using the Lego ACME library, it maintains valid, expired, and revoked certificates simultaneously — keeping a revoked cert non-expired is the hard part — with SNI-based selection via `GetCertificate`.
- **Go compiler keyword count:** Go has 25 reserved keywords, fewer than Python (35), C (43), Rust (48+), or Java (68). Useful framing for onboarding conversations.
- **TinyGo now supports 100+ boards:** Including ESP32s and the Game Boy Advance; GC is implemented but slow and unsupported on AVR and WASM targets; no wireless support yet.
- **vif PHP package manager:** Written in Go, uses PubGrub dependency resolution (same as Python's uv), benchmarks at ~8.4s vs Composer's ~18s on cached runs; pre-alpha but produces compatible `composer.lock` files.
- **watgo WASM toolkit:** Zero-dependency Go library and CLI for parsing, validating, encoding, and decoding WebAssembly modules; passes the full official spec test suite.
- **pgit Linux kernel import:** Stored 1.4M commits and 24.4M file versions in a 6.6 GB Postgres database in 2 hours; full-history SQL queries run in seconds.
- **Sky language:** Experimental Elm-inspired language that compiles to Go, with Hindley-Milner types, exhaustive pattern matching, and a Phoenix LiveView-style server-driven UI framework; compiler is self-hosted.
- **PlanetScale Postgres traffic control patterns:** Practical Go patterns for per-service isolation, route-level tagging via HTTP middleware, and graceful degradation on blocked queries using `SQLSTATE 53000`.

## Similar posts on daily.dev

- [April 2026 Outage Post-Mortem - Jim's Pckt](https://daily.dev/posts/april-2026-outage-post-mortem---jim-s-pckt-rxhhl4gj7) · Hacker News · 0 upvotes · 0 comments
- [Thoughts on the Bluesky public incident write-up](https://daily.dev/posts/thoughts-on-the-bluesky-public-incident-write-up-7m6kk8i9e) · Surfing Complexity · 32 upvotes · 1 comments

---

Tags: [#golang](https://daily.dev/tags/golang)

[View this post on daily.dev](https://daily.dev/posts/bluesky-s-goroutine-death-spiral-two-go-compiler-memory-safety-bugs-rmlykild4)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"DiscussionForumPosting","mainEntityOfPage":"https://daily.dev/posts/bluesky-s-goroutine-death-spiral-two-go-compiler-memory-safety-bugs-rmlykild4","headline":"Bluesky's goroutine death spiral, two Go compiler memory safety bugs","text":"A Go-focused roundup covering four major stories: Bluesky's post-mortem on an 8-hour outage caused by unbounded goroutine concurrency exhausting TCP ports and cascading into OOMs (fixed with a single errgroup.SetLimit call); two Go compiler bugs up to v1.26.1 that break memory safety guarantees using only safe code via flawed optimization passes; the constmap library offering 3x faster and 6x more memory-efficient immutable string map lookups using binary fuse filters; and Google's Agent Development Kit for Go reaching v1.0 with OpenTelemetry and self-healing support. Also covered: the Solod Go-to-C11 transpiler, Bloom filters in production at 18k req/s, TinyGo supporting 100+ boards, and several other Go ecosystem projects.","url":"https://daily.dev/posts/bluesky-s-goroutine-death-spiral-two-go-compiler-memory-safety-bugs-rmlykild4","datePublished":"2026-04-13T04:17:48.332Z","dateModified":"2026-04-13T04:18:07.893Z","author":{"@type":"Organization","name":"Go Digest","logo":"https://media.daily.dev/image/upload/s--8Aro536C--/f_auto,q_auto/v1773839403/logos/golang_digest?_a=BAMAMiiu0","url":"https://daily.dev/sources/golang_digest"},"interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":3},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"isPartOf":{"@type":"WebPage","url":"https://daily.dev/sources/golang_digest","name":"Go Digest"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Go Digest","item":"https://daily.dev/sources/golang_digest"},{"@type":"ListItem","position":3,"name":"Bluesky's goroutine death spiral, two Go compiler memory safety bugs"}]}
```

