Visitor publication

Cloudflare abandoned Nginx and switched to self-developed Pingora software written in Rust

Posting time:2023-03-26 11:35:32

Cloudflare abandoned Nginx and switched to self-developed Pingora software written in Rust

Cloudflare has long relied on Nginx as part of its HTTP proxy stack. But now, it has been replaced with self-developed Pingora software written in Rust. The company claims that Pingora can handle more than a trillion requests per day. While providing higher performance, the overhead of CPU and memory resources is only one-third of the old solution. It is reported that Cloudflare found flaws in Nginx's worker process architecture - especially in terms of CPU resources. Also Nginx proved difficult to scale to meet their needs. With this in mind, Cloudflare engineers have been working hard on in-house solutions and opted for the Rust programming language, which offers greater memory safety while still offering near-C performance. It's worth mentioning that Cloudflare also implements its own HTTP library for Rust to meet its various needs. In addition, Pingora uses a multi-threaded rather than a multi-process architecture. Finally, in a production environment, Pingora can reduce CPU and memory resource overhead by about 70% / 67% for older services under the same traffic load. In addition to the amazing performance benefits, the Rust programming language also plays a large role in ensuring the security of Pingora. The only pity is that Pingora is not yet open source - although Cloudflare says it is working on plans, the HTTP proxy is currently only used by the company.

Top ranking

Links