Skip to content

Commit

Permalink
Merge pull request #326 from mxinden/rfc/circuit-v2
Browse files Browse the repository at this point in the history
relay/circuit-v2: Replace excalidraw with plantuml
  • Loading branch information
vyzo authored May 11, 2021
2 parents 8bea5d0 + 5efd8e8 commit cf3e6d2
Show file tree
Hide file tree
Showing 3 changed files with 80 additions and 1 deletion.
42 changes: 41 additions & 1 deletion relay/circuit-v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,47 @@ Peer _A_ is a private peer, which is not publicly reachable; it
utilizes the services of peer _R_ as the relay. Peer _B_ is another
peer who wishes to connect to peer _A_ through _R_.

![Circuit v2 Protocol Interaction](circuit-v2.png)
![Circuit v2 Protocol Interaction](circuit-v2.svg)

<details>
<summary>Instructions to reproduce diagram</summary>

Use https://plantuml.com/ and the specification below to reproduce the diagram.

```
@startuml
participant A
participant R
participant B
skinparam sequenceMessageAlign center
== Reservation ==
A -> R: [hop] RESERVE
R -> A: [hop] STATUS:OK
hnote over A: Reservation timeout approaching.
hnote over A: Refresh.
A -> R: [hop] RESERVE
R -> A: [hop] STATUS:OK
hnote over A: ...
== Circuit Establishment ==
B -> R: [hop] CONNECT to A
R -> A: [stop] CONNECT from B
A -> R: [stop] STATUS:OK
R -> B: [hop] STATUS:OK
B <-> A: Connection
@enduml
```

</details>


The first part of the interaction is _A_'s reservation of a relay slot
in _R_. This is accomplished by opening a connection to _R_ and
Expand Down
Binary file removed relay/circuit-v2.png
Binary file not shown.
39 changes: 39 additions & 0 deletions relay/circuit-v2.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit cf3e6d2

Please sign in to comment.