Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Topics Compilers & runtimes

Concurrency

Threads, async/await, locks, lock-free structures, actors.

Search within Concurrency, or combine it with other topics →

2026

OLX Tech

Handling concurrency on the Web with Web Locks API

Case study 6 min +60 XP

OLX uses the browser's Web Locks API to stop multiple open tabs from each resuming the same large (up to 20GB) S3 upload after a restart. localStorage-plus-polling suffers from non-atomic writes and stale locks, and BroadcastChannel forces you to hand-roll a coordination protocol, whereas navigator.locks offers an atomic mutex that is released automatically when a tab closes or crashes.

ClickHouse

Designing the new async-native ClickHouse Python client

Deep dive 12 min +120 XP

The new async-native clickhouse-connect client replaces the legacy thread-pool wrapper with aiohttp for network I/O and a half-sync/half-async design: an async producer streams response chunks into a bounded queue (10 chunks of up to 1MB) while the existing synchronous Native-format parser consumes them in an executor thread, with the same queue reversed for inserts.

2025

Upgrade to Puma 7 and Unlock the Power of Fair Scheduled Keep-alive

Deep dive 11 min +110 XP

Puma 6 and earlier let a single keep-alive connection monopolize a thread for up to 10 requests via the "fast inline" loop originally built for HTTP pipelining, so under overload about one in ten requests waited roughly 10x longer while later keep-alive requests cut the line.

2024

2023

Bun

Bun v0.7.0

Release 10 min +100 XP

Bun v0.7.0 focuses on Node.js compatibility: it can now run `vite dev` (experimentally, via `bun --bun` to override the node shebang), supports Web `Worker` threads with `postMessage` and `structuredClone()`, and implements `AsyncLocalStorage` from `node:async_hooks` as a step toward Next.js support.

2022

2021

2020

2012

Undated

The quest for software engineering knowledge.

Look:
Layout: