The primary dies at 3 a.m. — System design

A database must survive its main server failing at night, with no one awake to promote a copy. Design the failover so a copy takes over safely.

All system design challenges