explaingit

taobao/nginx-book

6,972PythonAudience · developerComplexity · 4/5LicenseSetup · easy

TLDR

A free Chinese-language book written by Taobao's server team that teaches Nginx module development from scratch, then dives into Nginx internals, covering architecture, the event loop, request handling pipelines, and core data structures.

Mindmap

mindmap
  root((repo))
    What it covers
      Module development
      Nginx internals
      Request pipelines
      Event loop
    Content structure
      Beginner to expert
      Architecture chapters
      Core data structures
    Use cases
      Write custom modules
      Understand internals
      High perf design
    Audience
      C developers
      Systems engineers
    Notes
      Chinese language only
      Free to read online
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Learn how to write a custom Nginx module by following structured chapters that build from beginner to expert.

USE CASE 2

Understand how Nginx processes HTTP requests through its multi-stage pipeline, including subrequests.

USE CASE 3

Study how Nginx's event loop handles thousands of connections without blocking for high-performance server design.

Tech stack

Nginx

Getting it running

Difficulty · easy Time to first run · 5min

Content is entirely in Chinese, the full book is read online at the Tengine project website linked in the README.

Free to read, download, and share with attribution, but you may not sell it, print it commercially, or republish it as a standalone work, source code samples may be used freely in your own programs.

In plain English

This repository is a Chinese-language book about Nginx, the popular web server software. The title translates roughly to "Nginx Development: From Beginner to Expert." It was written by members of the core server platform team at Taobao, the large Chinese e-commerce company, who used Nginx heavily in their own infrastructure. The book starts with module development for Nginx and gradually moves into explaining how Nginx works internally. That progression, from building on top of Nginx to understanding its internals, is the stated structure of the content. The README is written in Chinese and the book itself is in Chinese. The content covers areas like the basic Nginx architecture and core data structures, configuration parsing, the event module, request reading and handling, subrequests, and multi-stage request processing pipelines. The update history in the README shows the book was actively developed from early 2012 through late 2013, with chapters added and revised over that period. The book is free to read, download, save, and share as long as you link back to the original publication site. You cannot sell it, print it commercially, or publish it as a standalone work. The source code samples included in the book can be used freely in your own programs, though the authors take no responsibility for issues that arise from using that code. If you are looking to understand how Nginx modules are built or how Nginx processes requests under the hood, this book is a structured guide to those topics. It is aimed at developers and system administrators who want to go beyond simply configuring Nginx and actually understand or extend how it works. The full text can be browsed at the Tengine project website linked in the README.

Copy-paste prompts

Prompt 1
I want to write a custom Nginx module. Walk me through the basic module structure and how to register a handler using the concepts from the Taobao nginx-book.
Prompt 2
Explain how Nginx's event module works and how it handles many simultaneous connections without blocking threads, based on the nginx-book internals chapter.
Prompt 3
Show me how Nginx processes an HTTP request step by step through its multi-stage pipeline from reading the request to sending the response.
Prompt 4
Where can I read the full taobao/nginx-book online, and how are its chapters organized so I know where to start?
Open on GitHub → Explain another repo

← taobao on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.