Chandra–Toueg consensus algorithm: Difference between revisions

Content deleted Content added
No edit summary
Line 5:
 
# All processes send (r, preference, timestamp) to the coordinator.
# The coordinator waits to receive messages from at least half of the processes (including itself).
## It then chooses as its preference a value with the most recent timestamp among those sent.
# The coordinator sends (r, preference) to all processes.
# Each process waits (1) to receive (r, preference) from the coordinator or (2) for its failure detector to identify the coordinator as crashed.
## In the first case, it sets its own preference to the coordinator's preference and responds with ack(r).
## In the second case, it sends nack(r) to the coordinator.
# The coordinator waits to receive ack(r) or nack(r) from a majority of processes.
## If it receives ack(r) from a majority, it sends decide(preference) to all processes.
# Any process that receives decide(preference) for the first time sends decide(preference) to all processes, then decides preference and terminates.