"Distributed Computing" Chapter 2 Study Notes

2.1 Distributed program

Distributed system: a system in which components are distributed on different computer nodes, and different nodes communicate through message passing, and coordinate with each other to complete tasks.

C i j C_{ij} Cij: process iii to processjjmessage channel between j

m i j m_{ij} mij: process iii is sent to processjjj 's news

Global state: The global state of a distributed system consists of the state of all processes and the state of all communication channels.

2.2 Distributed operation model

e i x e_i^x eix: process iii 'sxxx events.

s e n d ( m ) send(m) se n d ( m ) : send event of message m.

r e c ( m ) rec(m) rec ( m ) : Receive event for message m.



Distributed space-time graph:
insert image description here

Figure 1 Distributed space-time diagram


H H H : collection of events in the process of distributed computing

a → b a\rightarrow b ab : eventaaa precedes eventbbb happens.

∀ eix , ejy ∈ H , eix → ejy ⇔ { eix → ejy , ( i = j ) and ( x < y ) (events in the same process) eix → msgejy (message passing) eix → ejy and eix → ejy ( Transitive) \forall e_i^x,e_j^y \in H,e_i^x\rightarrow e_j^y \Leftrightarrow \left\{ \begin{matrix} e_i^x\rightarrow e_j^y,(i=j)~ ~and~~(x<y) (events in the same process) \\ \\ e_i^x\rightarrow _{msg}e_j^y (message passing) \\ \\ e_i^x\rightarrow e_j^y~ ~and~~e_i^x\rightarrow e_j^y (transitive)\\ \end{matrix} \right.eix,ejyHeixejy eixejy,(i=j)  and  (x<y ) (events in the same process)eixmsgejy(messaging)eixejy  an d e  ixejy(transitive )

This is an anti-reflexive partial ordering relationship.



ei ∣ ∣ ej e_i||e_jei∣∣ej e i ↛ e j   a n d   e j ↛ e i e_i \not \rightarrow e_j ~and~e_j \not \rightarrow e_i eiej an d e jei(concurrent)

2.4 Global State of Distributed Systems

L S i x LS_i^x LSix: Processor at event eix e_i^xeixAfter that happens, and event eix + 1 e_i^{x+1}eix+1state before

S C i j x , y SC_{ij}^{x,y} SCijx,y: channel C ij {C_{ij}}CijIn process pi p_ipiuntil event eix e_i^xeixThe message sent and the process pj p_jpjuntil event ejy e_j^yejyunreceived message

insert image description here

Figure 2 Channel status

2.5 Segmentation of distributed computing

        ~~~~~~~        Drawing a zigzag line intersecting a certain point of each process line can divide the entire calculation process into two parts, and this zigzag line is called a splitting line.
        ~~~~~~~       This line divides the space-time graph into two parts, and also divides all distributed computing events into two sets, called the past (PAST) set and the future (FUTURE) set. The PAST collection contains all events to the left of the dividing line, and the FUTURE collection contains all events to the right of the dividing line.


insert image description here

Figure 3 Dividing line


insert image description here

Figure 4 Global state of the dividing line

2.6 The past and future of events

P a s t ( e j ) = { e i   ∣   ∀ e i ∈ H , e i → e j } Past(e_j)=\{e_i~|~\forall e_i\in H,e_i\rightarrow e_j\} Past(ej)={ ei  eiH,eiej}

F u t u r e ( e j ) = { e i   ∣   ∀ e i ∈ H , e j → e i } Future(e_j)=\{e_i~|~\forall e_i\in H,e_j\rightarrow e_i\} Future(ej)={ ei  eiH,ejei}

Guess you like

Origin blog.csdn.net/weixin_46878177/article/details/127347820