← Back to projects

Distributed Database Performance Optimization

DatabasesDistributed SystemsPerformance

Led infrastructure work to reduce tail latencies and improve query planning for a distributed database system.

Context & Problem

A distributed DB startup had customers reporting unpredictable query latencies, especially in multi-region deployments. This was becoming a blocker for enterprise sales.

Role & Responsibilities

Staff engineer, responsible for query planner and replication layer improvements.

Architecture & Key Decisions

Rewrote query planning logic to optimize for geo-locality, implemented replica preference hints, added cost-based routing for follower reads.

Impact & Outcomes

Reduced p99 latency by 65%, cut customer-reported slowdowns by 80%, enabled enterprise sales to close 3 major deals.

What I'd Do Differently

Understanding the actual bottleneck beats generic optimization. Spend time with customers and trace real queries. Replica selection and follower reads unlock a lot of performance without major rewrites.

Built with v0