Add proper sequence diagram mscgen

This commit is contained in:
Oskar Thoren 2019-09-24 13:31:27 +08:00
parent 693b6e3414
commit 32829cb123
No known key found for this signature in database
GPG Key ID: B2ECCFD3BC2EF77E
3 changed files with 32 additions and 16 deletions

21
remote_log/remote-log.msc Normal file
View File

@ -0,0 +1,21 @@
# Alice and Bob: remote log data sync
msc {
hscale="2", wordwraparcs=on;
alice [label="Alice"],
bob [label="Bob"],
cas [label="CAS"] ,
ns [label="NS"];
--- [label="Alice replicates data to a remote log"];
alice => cas [label="Add content"];
cas => alice [label="Address"];
alice => ns [label="Update NameUpdate"];
ns => alice [label="Response"];
--- [label="Bob comes online"];
bob => ns [label="Fetch"];
ns => bob [label="Content"];
bob => cas [label="Fetch Query"];
cas => bob [label="Content"];
}

BIN
remote_log/remote-log.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -1,6 +1,6 @@
# Remote log specification # Remote log specification
> Version: 0.0.4 (Draft) > Version: 0.0.5 (Draft)
> >
> Authors: Oskar Thorén oskar@status.im, Dean Eigenmann dean@status.im > Authors: Oskar Thorén oskar@status.im, Dean Eigenmann dean@status.im
@ -115,6 +115,8 @@ message RemoteLog {
## Synchronization ## Synchronization
<!-- TODO: Elaborate on interaction with MVDS, especially with what messages are synced, etc -->
### Roles ### Roles
There are three fundamental roles: There are three fundamental roles:
@ -125,24 +127,17 @@ There are three fundamental roles:
Additionally, the *remote log* protobuf is what is stored at the Name system. Additionally, the *remote log* protobuf is what is stored at the Name system.
<!-- If two parties, Alice and Bob, are synchronizing, then node is split into two roles -->
### Flow ### Flow
```mermaid <!-- diagram -->
sequenceDiagram
Alice->>CAS: Add content
CAS->>Alice: Address
Alice->>NS: Update NameUpdate
NS->>Alice: Response
Bob->>NS: Fetch
NS->>Bob: Content
Bob->>CAS: Fetch Query
CAS->>Bob: Content
```
<!-- TODO: Actually in-line this sequence diagram -->
<p align="center">
<img src="./remote-log.png" />
<br />
Figure 1: Remote log data synchronization.
</p>
## Footnotes ## Footnotes