Skip to content
duang@blog:~$

Duang

help · grep · cat · today · 也可把文章拖进终端

Posts

正在写请求过境 · IdleTimeout 与代理 idle

Latest Digest

1 posts

What I've been reading lately.

Enter column

thinking

1 posts

A few small thoughts.

Enter column

Agent Breakdowns

2 posts

Loops, tools, and engineering trade-offs in Agent projects.

Enter column

Agent System Architecture

0 posts

Define the boundary, climb the spectrum, and design without a framework first.

Enter column

Nothing here yet.

Pi Deep Dive

0 posts

What Pi is, how the packages split, and which trade-offs it made.

Enter column

Nothing here yet.

MySQL

0 posts

Walk one SQL through architecture, engine, indexes, and transactions.

Enter column

Nothing here yet.

High-Performance Backend

0 posts

Measure first, then dig into CPU, memory, concurrency, and I/O — Python and Go side by side.

Enter column

Nothing here yet.

Easy-to-Mix Notes

1 topics

Split concepts that get tangled: process, thread, coroutine, and more.

Enter column

Backend Notes

2 posts

Server boundaries, timing, and real failures from one request.

Enter column

Frontend Lab

4 posts

Interactive browser experiments with working code.

Enter column

Notes & Other

2 posts

Loose notes that have not grown into a column yet.

Enter column

The same job, written once in Go and once in Python

Column samples come in both languages. Switch tabs to see how one job is done on each side.

sem := make(chan struct{}, 8)
var wg sync.WaitGroup

for _, u := range urls {
    wg.Add(1)
    go func(u string) {
        defer wg.Done()
        sem <- struct{}{}
        defer func() { <-sem }()
        fetch(u)
    }(u)
}

wg.Wait()