mirror of https://github.com/vacp2p/rfc.git
Update on the rln registration figure to match the current spec (#497)
* updates the rln registration figure to match the current spec * better illustration of block mining * moves labels above the arrows
This commit is contained in:
parent
6498d927d9
commit
bb57e3e566
|
@ -0,0 +1,33 @@
|
|||
# Sequence diagram for RLN Relay protocol (registration)
|
||||
msc {
|
||||
hscale = "2";
|
||||
|
||||
d [label = " "], a [label = " "],b [label = " "];
|
||||
a rbox a [label="Relay Node A"],
|
||||
b note b [label="Membership Contract"],
|
||||
d rbox d [label = "Relay Node B"];
|
||||
|
||||
b abox b [ label=" \n Listening to the membership contract \n "] ;
|
||||
|
||||
a box a [ label=" \n Generate sk,pk \n "] ;
|
||||
a=>b [ label = " \n Register(pk, x ETH) \n " ] ;
|
||||
a box a [ label=" \n Listening to the membership contract \n "] ;
|
||||
|
||||
b box b [label=" \n Insert pk as a leaf to the tree \n \n index: The index of the inserted leaf \n \n root: The updated tree root \n \n authPath: The authentication path \n "];
|
||||
|||;
|
||||
b=>a [ label = "index, root, authPath"];
|
||||
|||;
|
||||
..., ---;
|
||||
... [ label = "Other relay nodes register and the membership tree gets updatetd" ];
|
||||
..., ---;
|
||||
a=>b [ label = "getRoot()" ] ;
|
||||
b box b [label=" \n root: Get the current root\n "];
|
||||
b=>a [ label = "root"];
|
||||
|
||||
..., --- [ label = " " ];
|
||||
|
||||
a=>b [ label = "getAuthPath(index)" ] ;
|
||||
b box b [label=" \n authPath: Calculate the authentication path of the leaf with the given index and based on the current tree\n "];
|
||||
|
||||
b=>a [ label = "authPath"];
|
||||
}
|
|
@ -1,32 +1,25 @@
|
|||
# Sequence diagram for RLN Relay protocol (registration)
|
||||
msc {
|
||||
hscale = "2";
|
||||
hscale = "1.3";
|
||||
|
||||
d [label = " "], a [label = " "],b [label = " "];
|
||||
a rbox a [label="Relay Node A"],
|
||||
b note b [label="Membership Contract"],
|
||||
d rbox d [label = "Relay Node B"];
|
||||
|
||||
|||;
|
||||
d abox d [ label=" \n Listening to the membership contract \n "] ;
|
||||
|
||||
a box a [ label=" \n Generate sk,pk \n "] ;
|
||||
a=>b [ label = " \n Register(pk, x ETH) \n " ] ;
|
||||
a=>b [ label = "Register(pk, x ETH)" ] ;
|
||||
a abox a [ label=" \n Listening to the membership contract \n "] ;
|
||||
|
||||
b box b [label=" \n Insert pk to the list. \n Emit an event announcing the insertion of pk and its index in the list. \n "];
|
||||
|||;
|
||||
---;
|
||||
b abox b [ label=" \n Block containing the insertion transaction is mined \n "] ;
|
||||
b=>a [ label = "Insert(pk, index)"];
|
||||
b=>d [ label = "Insert(pk, index)"];
|
||||
|
||||
b box b [label=" \n Insert pk as a leaf to the tree \n \n index: The index of the inserted leaf \n \n root: The updated tree root \n \n authPath: The authentication path \n "];
|
||||
|||;
|
||||
b=>a [ label = "index, root, authPath"];
|
||||
|||;
|
||||
..., ---;
|
||||
... [ label = "Other relay nodes register and the membership tree gets updatetd" ];
|
||||
..., ---;
|
||||
a=>b [ label = "getRoot()" ] ;
|
||||
b box b [label=" \n root: Get the current root\n "];
|
||||
b=>a [ label = "root"];
|
||||
|
||||
..., --- [ label = " " ];
|
||||
|
||||
a=>b [ label = "getAuthPath(index)" ] ;
|
||||
b box b [label=" \n authPath: Calculate the authentication path of the leaf with the given index and based on the current tree\n "];
|
||||
|
||||
b=>a [ label = "authPath"];
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 70 KiB After Width: | Height: | Size: 97 KiB |
Loading…
Reference in New Issue