AI-built Rust Multi-Paxos reimplements Azure RSL with 100K lines
A three-month Rust build turned Azure RSL’s Multi-Paxos into a 100K-line engine, and AI-generated contracts even caught a Paxos safety bug.

A Multi-Paxos engine that crossed 100,000 lines of Rust did not start with a grand rewrite plan. It started with a practical question: could AI help turn a notoriously hard distributed-systems implementation into something a Rust team could actually finish, verify, and tune without losing safety?
The answer, in this case, was a production-grade reimplementation of Azure’s Replicated State Library, the Paxos engine used across Azure and Bing. The new code aimed to preserve RSL’s core features, including dynamic replica set reconfiguration, service-healing, durable journal files, periodic snapshots, and multi-rings per process, while modernizing the system for current hardware. The team identified three gaps in the older design: no pipelining, no NVM support, and limited awareness of hardware features such as RDMA.
The work reportedly took about three months end to end. Roughly 100,000 lines of Rust were written in about four weeks, then pushed through a three-week performance pass that lifted throughput from about 23,000 operations per second to 300,000 operations per second. Along the way, the project accumulated more than 1,300 tests covering unit, integration, and failure scenarios, which is exactly the kind of volume a protocol like Multi-Paxos demands when crashes, retries, and reconfiguration all happen in the same system.
What makes the build unusual is the way AI was used. The workflow combined multiple coding agents, including GitHub Copilot, Claude Code, and Codex CLI, but the more interesting layer was the contract work. AI-generated code contracts were turned into runtime assertions during testing, and one of those contracts exposed a subtle Paxos safety violation. That matters because Multi-Paxos is not just another replicated service. It is the consensus core underneath state machine replication, the part that keeps services correct when machines crash or networks misbehave.

That pressure is familiar to Microsoft Research, which has long treated distributed consensus as essential infrastructure and has already presented formal TLA+ specifications and mechanically checked safety proofs for Multi-Paxos. A 2024 paper, MultiPaxos Made Complete, argued that implementation guidance is still incomplete. This Rust build sits right in that gap: not as proof that the problem is solved, but as a concrete engineering case where AI, specs, and property-based testing made a 100K-line consensus engine tractable.
For Rust developers who spend their nights chasing races and invariants, that is the real story. The win was not that AI wrote a distributed system. The win was that Rust, contracts, and tests gave a hard protocol enough structure to make the bug hunt and the performance work feel survivable.
Know something we missed? Have a correction or additional information?
Submit a Tip

