Logo
Grokking the Advanced System Design Interview
Ask Author
Back to course home

0% completed

Locks, Sequencers, and Lock-delays

Let's explore how Chubby implements Locks and Sequencers.

Locks

Each chubby node can act as a reader-writer lock in one of the following two ways:

  • Exclusive: One client may hold the lock in exclusive (write) mode.
  • Shared: Any number of clients may hold the lock in shared (reader) mode.

Sequencer

With distributed systems, receiving messages out of order is a problem; Chubby uses sequence numbers to solve this problem. After acquiring a lock on a file, a client can immediately request a 'Sequencer,' which is an opaque byte string describing the state of the lock:

**Sequenc

.....

.....

.....

Like the course? Get enrolled and start learning!