System Design · Airbnb · Medium
Requirements The system revolves around three tables: Listings, Reservations, and Pricing. For a host who owns a large number of listings, and for a date range the user selects, the page must show nights_booked and avg_price for each of that host's listings. The page has to render in under a second. What the design has to address Diagnose before you fix. Start by tracing the straightforward query plan and explain where its cost comes from — joining three big tables and…
Checking your access…