forked from zigbee-alliance/distributed-compliance-ledger
-
Notifications
You must be signed in to change notification settings - Fork 0
/
use_cases_add_validator_node.puml
47 lines (34 loc) · 1011 Bytes
/
use_cases_add_validator_node.puml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
@startuml
!pragma teoz true
hide footbox
actor "ZA Trustee 1" as T1
actor "ZA Trustee N" as TN
database Ledger as L
actor "Node Admin" as NA
== Genesis Block ==
note over L
4 Node transactions
4 Accounts with NodeAdmin roles
end note
== Add a new validator node ==
NA -> NA: generate Account keys
NA -> T1: send account's pubKey
T1 -> L: PROPOSE_ADD_ACCOUNT(role=NodeAdmin; pubKey)
alt if more than 1 Trustee signature is required for role NodeAdmin
TN -> L: APPROVE_ADD_ACCOUNT
end alt
L -> L: a new Account with role=NodeAdmin is created
NA -> NA: generate Node's key
NA -> L: ADD_VALIDATOR_NODE
== Remove a validator node by Trustee(s) ==
T1 -> L: PROPOSE_REMOVE_VALIDATOR_NODE
alt if more than 1 Trustee signature is required for revocation
TN -> L: APPROVE_REMOVE_VALIDATOR_NODE
end alt
L -> L: Node is removed
L -> L: Node's Account is removed
== Remove a validator node by NodeAdmin ==
NA -> L: REMOVE_VALIDATOR_NODE
== Rotate the node's key ==
NA -> L: UPDATE_VALIDATOR_NODE
@enduml