TimeandGlobalStatesTanenbaum1108

TimeandGlobalStatesTanenbaum1108 - Time and Global States...

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon
Time and Global States Part 3 ECEN5053 Software Engineering of Distributed Systems University of Colorado, Boulder
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
November 2, 2005ECEN5053 SW Eng of Distributed Systems, Time and 2 Topics Clock synchronization Logical clocks Vector timestamps Global State                                                
Background image of page 2
November 2, 2005ECEN5053 SW Eng of Distributed Systems, Time and 3 Vector Timestamps With Lamport logical clocks, nothing can be said about the relationship between a and b simply by comparing their timestamps C( a ) and C( b ). Just because C( a ) < C( b ), doesn’t mean a happened before b (remember concurrent events) Consider network news where processes post articles and react to posted articles Postings are multicast to all members Want reactions delivered after associated postings
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
November 2, 2005ECEN5053 SW Eng of Distributed Systems, Time and 4 Will totally-ordered multicasting work? That scheme does not mean that if msg B is delivered after msg A, B is a reaction to msg A. They may be completely independent. What’s missing? If causal relationships are maintained within a group of processes, then receipt of a reaction to an article should always follow the receipt of the article . If two items are independent , their order of delivery should not matter at all
Background image of page 4
November 2, 2005ECEN5053 SW Eng of Distributed Systems, Time and 5 Vector Timestamps capture causality VT( a) < VT(b) means event a causally precedes event b. Let each process Pi maintain vector Vi such that V i [i] is the number of events that have occurred so far at P i If V i [j] = x then P i knows that x events have occurred at P j We increment V i [i] at the occurrence of each new event that happens at process P i Piggyback vectors with msgs that are sent. When P i sends msg m, it sends its current vector along as a timestamp vt.
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
November 2, 2005ECEN5053 SW Eng of Distributed Systems, Time and 6 For example P 1 V 1 = [3,1,2] P 2 V 2 = [2,4,1] P 3 V 3 = [0,2,5] With a new event at P 2 , V 2 [2] = V 2 [2] + 1 If P3 receives a msg a from P1, V 3 [1] = vt(a)[1] + 1 where vt(a) = V 1
Background image of page 6
November 2, 2005ECEN5053 SW Eng of Distributed Systems, Time and 7 Receiver thus learns the number of events that have occurred at P i Receiver is also told how many events at other processes have taken place before P i sent message m. timestamp vt of m tells the receiver how many events in
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 8
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 24

TimeandGlobalStatesTanenbaum1108 - Time and Global States...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online