Databases: transactions, isolation levels and locking
Why correct code goes wrong under concurrency: ACID and how InnoDB implements it, isolation levels and anomalies (lost update, write skew), locks, gap locks, deadlocks, MVCC, SKIP LOCKED and retrying the right way.