zqw's notes
Posts About
zqw's notes
Cancel
PostsAbout

Go Singleflight Deep Dive: Preventing Cache Stampede with One Line of Code

Paul published on 2021-12-21 included in Go

In high-concurrency scenarios, cache stampede can crush your database. Singleflight solves this with an elegantly simple design.

Read More
 Concurrency, Caching, Source Code Analysis

Compiling Nginx from Source: Understanding Module Architecture and Custom Extensions

Paul published on 2021-12-06 included in Linux

Most people install Nginx via package managers, but compiling from source truly reveals its module mechanism. This post uses FastDFS module integration as an example to analyze Nginx’s build system and modular architecture.

Read More
 Nginx, Compilation, Modular Architecture

Postmortem: Debugging a Zookeeper Split-Brain in Production

Paul published on 2021-10-14 included in Distributed Systems

One night at 2 AM, Kafka message lag alerts fired. Investigation revealed a Zookeeper cluster split-brain — two nodes both thought they were the Leader. This post documents the full debugging and recovery process.

Read More
 Zookeeper, Debugging, High Availability

Go Microservices War Stories: 5 Lessons from Dependency Management to Service Discovery

Paul published on 2021-09-22 included in Distributed Systems

Microservices isn’t just about splitting up a monolith. This post documents 5 real pitfalls I hit in Go microservices projects, and how to avoid them.

Read More
 Go, GRPC, Debugging

Building a Mini Filesystem: Custom FS with FUSE + Go

Paul published on 2021-08-10 included in Linux

The best way to learn filesystems is to write one yourself. This post uses FUSE + Go to implement an in-memory filesystem with basic read/write operations, deep-diving into core concepts like inode and block.

Read More
 Filesystem, FUSE, Go

Redis Eviction Deep Dive: LRU vs LFU vs TTL Engineering Trade-offs

Paul published on 2021-07-03 included in Performance

Textbook LRU uses a doubly-linked list + HashMap. But why does Redis use “approximate LRU”? This post dives into Redis source code to analyze the engineering trade-offs behind different eviction strategies.

Read More
 Redis, Caching, Source Code Analysis
  • 1
  • 2
  • 3
  • 4
2019 - 2026 xxxx | CC BY-NC 4.0