Electing a leader — engine lab

Servers keep copies of a log and the leader crashes mid-update. See when a write is safe and who may lead next.