Open wolf-null opened 2 years ago
The node also has no idea about it's mirrors. This is why it can't send additional update signals to certain MasterHosts. For a Node there is only one MasterHost and all other Nodes.
Needless to mention: signal routing is already a responsibility of a Host.
One can propose a simple algorithm.
All Nodes and Hosts interact via the same signaling interface.
The mirror consistency problem
AwooNet uses Stages to traverse all the nodes and updates it's states (or the states of the mirror, for instance, mostly to build the metrics of the whole network for monitoring purposes). Technically, Stages implements a Visitor pattern.
On a local machine, if a Node updates it's state (own local database), this update is also mirrored to the local MasterHost via DataSignal.
If two MasterHosts (Local and Remote) are interconnected via some sort of virtual ProcessHost (which works via network), then this DataSignal has to be also retransmitted to the remote host (if we do wand to hold the consistency of mirrors... and we actually do due to the horizontality of MasterHosts)
MasterHost doesn't know if it's PocessHost is it real (local ProcessHost) or a virtual (networking) one. This is why it should be somehow a way to tell to MasterHost to retransmit all DataSignals for certain Hosts. On the other hand, this 'retransmission' of signals might be useful for advanced applications.
This leads us to the need of implementation of more advanced routing algorithms than dst --> dst which is now used.