Building ASP.NET Core Kestrel
summary
Kestrel is a managed, cross‑platform web server built on libuv and claims up to 20x faster throughput versus older ASP.NET by using pinned large‑object heaps, per‑thread slab pools, reuse of known ASCII strings as 64‑bit values, custom awaiters that map libuv callbacks to async/await, and CPU vectorization via SIMD. Benchmarks and demos show drastically fewer Gen2 GCs and lab runs around 5.5 million RPS, with pipelining, lock reduction and allocation avoidance as the concrete wins driving those numbers.
AI-written summary · about
chapters (26)
- 0:00Introduction
- 1:27What is Kestrel
- 5:38TechPower Benchmark
- 8:31Garbage Collection
- 14:05Memory
- 18:02Strings
- 20:20Known Strings
- 23:22Demo
- 29:26libuv
- 30:26asyncwait
- 33:10asynchronous
- 34:28multithreaded
- 35:52network stack
- 38:48pipeline
- 41:59libuv through
- 43:01algorithms
- 43:25seek
- 46:49Systemnumerix
- 52:15Finding Known Headers
- 52:54ASCII
- 54:30headers
- 56:14resharper
- 56:29fast code
- 57:07fixed by rate
- 57:26casting to memory
- 57:47final thoughts
related talks
01h 01mgRPC for ASP.NET Core, a new framework for high performance APIs
37mRock Your Code Code and App Performance for Microsoft .Net
12mWhen each millisecond counts?
39mReal-Time Arch for Modern ASP.NET Core Web Apps
06mInterview
01h 03mTurbocharged: Writing High-Performance C# and .NET Code
01h 00mRock Your Code: Code & App Performance for Microsoft .NET
01h 02mPerformance tricks I learned from contributing to the Azure .NET SDK
