Skip to content
Theory · Distributed basics · lesson 7 of 8

Time and the order of events

It seems natural to order events by time: a purchase at 12:00:01.005 happened after a hold was released at 12:00:01.000. But those two times were shown by the clocks of two different machines, and machine clocks drift apart. In an interview this comes up in any prompt where events from different places are merged into one history.

In this lesson

  • Why clocks drift apart
  • Last write by the clock
  • What sets the order
  • Which clock for what
  • Common mistake
  • Key points