forked from tteoz/OTRA
/
Protocol.txt
26 lines (15 loc) · 929 Bytes
/
Protocol.txt
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
# PROTOCOL MESSAGES
# all service is based around the following messages
TOUCH verify if the given host is up and running
HEIGHT send the height of the current subtree up to parent node
JOIN_BROADCAST broadcast signal to discover if there is an OTRA network already running
JOIN_RESPONSE response to handle incomer hosts
JOIN_SEARCH is propagated downward the tree two find the right position to attach the new joining host
BALANCE signal that there is the need of an balancing operation
SET_PARENT to change references in other host's routing table
SET_LEFT
SET_RIGHT
PRINT broadcast signal to force leaves host to send printing information upward
DISCONNECTED broadcast to discover sibling that lost their parent as well
DSCNN_RESPONSE siblings response to DISCONNECTED discovery
RECOVERY_FIND_MAX run in a given subtree find the host which has the greatest id value, this serves to merge two subtree into a new one