HiveBrain v1.2.0
Get Started
← Back to all entries
patternMinor

Are vector clocks useful in centralized systems?

Submitted by: @import:stackexchange-cs··
0
Viewed 0 times
aresystemscentralizedusefulclocksvector

Problem

Vectors clocks seem to be a common way to synchronize the partial ordering of events in a distributed, peer-to-peer, system across all clients.

Is there any benefit to using them in a centralized system, where one node in the system has the power to order all events anyway, to order events? If one computer can decide the order anyway, there would be no need for vector clocks, right?

Solution

No, there's no need for a vector clock in a centralized system.

A vector clock uses a $N$-vector of timestamps, where $N$ is the number of computers in the distributed system and the $i$th component of the vector block is a timestamp chosen by the $i$th computer. In a centralized system you'd use a $N$-vector with $N=1$, so it just reduces to a single number instead of a vector. In other words, instead of a vector, all you need is a single timestamp, where the timestamp is chosen by the central computer.

Context

StackExchange Computer Science Q#62801, answer score: 6

Revisions (0)

No revisions yet.