Senior Track Roadmap

Database: CockroachDB basics

CockroachDB is a relational database that spreads data across machines and keeps SQL transactions working. The lessons explain how tables are split into key ranges replicated through Raft, why every write needs a majority, and how clock uncertainty causes transaction retries. They cover which Postgres features and Active Record code carry over, why sequential primary keys create hot ranges, and how REGIONAL BY ROW and GLOBAL tables place data. The course ends by costing a migration of this application and naming the facts that would change the answer.

What you'll learn

  • ✓How key ranges, replication and Raft consensus shape write latency
  • ✓Why clock uncertainty restarts transactions and why code needs retry loops
  • ✓Which Postgres features carry over to CockroachDB and which break
  • ✓Why sequential primary keys create hot ranges
  • ✓Placing data with REGIONAL BY ROW and GLOBAL tables
  • ✓Weighing a migration against triggers you can measure
Free preview · Lesson 1 3 min read

What distributed SQL means

Distributed SQL claims you can have a relational database with transactions and joins, spread across many machines, without sharding it yourself. That claim deserves a careful look, because half of it is true and the other half has a price.

Read the full lesson free →

Curriculum

7 lessons
Type to start searching...