Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Three computers A, B, and C communicate using a protocol that implements the idea of Lamport clocks (they include their clock timestamp in messages).
Three computers A, B, and C communicate using a protocol that implements the idea of Lamport clocks (they include their clock timestamp in messages). For reference, if you need a reminder, recall that the three rules of Lamport's algorithm are: Rule 1: At process i, increment C; after every local event. Rule 2: To send message m at process i, include the current local time in the message, i.e., send(m, C), then apply apply Rule 1. Rule 3: To receive a message (m;t) at process j, process j updates its local clock C, to be C = max(C;;t + 1). At the beginning of time, all three computers begin with their logical clock set to zero (0). Later, the following sequence of events occurs: A sends message M1 to B: "hi". After sending M1, A sends message M2 to C: "hi" After receiving M1, B sends message M3 to C: "A said hi to me" After receiving M3 first and then M2, C sends message M4 to A: "B is boring" (a) Indicate the time included with the messages as they are sent at each step. Send (M1, ) ) ) ) (b) Maintaining all clock states from the previous question, three ADDITIONAL messages are sent: After receiving M4, A sends message M5 to B: "C is kind of random!" After receiving M5, B sends message M6 to A: "C is boring" A receives message M6 Send (M2, Send (M3, Send (M4, After all of these messages have been sent and received, what time does each computer think it is? (c) Is this a relatively or totally ordered system? (d) Write out the vector time representation with the following messages as they are sent at each step. Send (M1, [ Send (M2, [ Send (M3, [ Send (M4, [ ]) 1) ]) 1)
Step by Step Solution
★★★★★
3.46 Rating (153 Votes )
There are 3 Steps involved in it
Step: 1
Lets analyze the events step by step and calculate the Lamport logical clock timestamps at each event for the given sequence of events At the beginning all three computers have their logical clocks se...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started