← All components
Databases & search
Relational database
ACID SQL store for transactional data: users, orders, payments, bookings.
When to use
- Money and inventory
- Data with relations and strong consistency needs
Pitfalls
- Write scaling needs sharding or a distributed SQL engine
Options by provider
The first option is what diagrams show for that provider.
Amazon Web Services
- Amazon AuroraManaged
- Amazon RDSManaged
Google Cloud
- Cloud SQLManaged
- AlloyDBManaged
- Spanner — globally distributed SQLManaged
Microsoft Azure
- Azure Database for PostgreSQLManaged
- Azure SQL DatabaseManaged
Open source / self-hosted
- PostgreSQLSelf-hosted
- MySQLSelf-hosted
- VitessSelf-hosted
- CockroachDBSelf-hosted
Related concepts
Used in
- Netflix
- Accounts DB — Accounts, plans and billing
- Catalogue DB — Title and episode metadata
- Instagram
- Users, posts & follows — Sharded by user, with read replicas
- Twitter / X
- Users & follows — Profiles and the follow graph
- WhatsApp / Messenger
- Users & groups — Accounts, conversations and memberships
- Uber
- Trips & accounts — Rides, riders, drivers and payments, sharded by city
- Amazon
- Payment gateway
- Transactions — Payments, refunds and disputes
- Ledger — Append-only double-entry journal
- API rate limiter
- Rules DB — All rate-limit rules
- Dropbox
- Metadata & journal — File versions and per-folder change log
- BookMyShow
- Bookings & seats — Source of truth for sold seats
- MakeMyTrip
- Bookings — Bookings and their steps
- Airline reservations
- Airbnb
- Listings, calendars & reservations — Sharded by listing
- NoBroker
- Listings, users & plans — Transactional data
- Meeting scheduler
- Events & rooms — Meetings, attendees and room bookings
- Car rental
- Inventory, reservations & fleet — Source of truth
- Zomato / food delivery
- Orders — Orders by city
- Urban Company
- Bookings & schedules — Source of truth
- Porter / goods delivery
- Orders — Orders by city
- Driver booking & fleet management
- Drivers, bookings & shifts — Source of truth
- Practo / teleconsultation
- Appointments & slots — Source of truth
- AstroTalk
- Wallet ledger — Double-entry wallet movements
- Quora
- Questions, answers & follows — Sharded relational store
- LinkedIn
- Profiles & jobs — Sharded by member / company
- Buy now, pay later
- Ledger & credit lines — Double-entry ledger and limits
- Stock brokerage
- Orders & trades — Order book of record
- Funds & positions — Ledger and holdings