Lei Zhao is a seasoned web developer based in Shanghai with a decade of hands-on experience in backend systems and distributed databases. He is a pragmatic open-source contributor to high-profile projects like TiKV, TiDB, and KeyDB, focusing on transaction semantics, lock resolution, and reliability under concurrency. His work shows deep expertise in pessimistic transaction handling, region cache optimization, and protocol buffer design—areas that materially improve production safety and performance. Lei combines careful bug-fixing and refactoring with feature additions, often addressing subtle panic scenarios and race conditions that are easy to miss in large codebases. Colleagues would recognize him for turning theoretical correctness into practical, test-covered fixes—consistent with his self-aware motto about combining theory and practice. Comfortable in Go and C codebases, he thrives on improving core infrastructure rather than building flashy front-ends.
Contributions:28 reviews, 14 commits, 40 PRs in 2 years 10 months
Contributions summary:Lei contributed to the `kvproto` repository, which contains protocol buffer definitions for TiKV. The commits primarily focused on modifying `.proto` files and related generated Go code, indicating work on defining and modifying data structures for communication within the TiKV system. These changes included adding features like lock wait timeout and supporting get latest value functionalities within the pessimistic locking mechanism. The user also added committed_locks to Context to improve resolving locks for read operations.
Distributed transactional key-value database, originally created to complement TiDB
Role in this project:
Back-end Developer
Contributions:7 releases, 548 reviews, 218 commits in 3 years 5 months
Contributions summary:Lei made several contributions related to the pessimistic transaction feature in TiKV, including implementing pessimistic rollback functionality. They modified the codebase to handle non-pessimistic lock conflicts and incorporated optimizations like removing unnecessary wake-up messages in the waiter manager. Furthermore, they added metrics and configuration options to the lock manager, improving its performance and functionality.
tidbtikvdatabasekey-value-databaseconsensus
Find and Hire Top DevelopersWe’ve analyzed the programming source code of over 60 million software developers on GitHub and scored them by 50,000 skills. Sign-up on Prog,AI to search for software developers.