Broadcast neighbourhood; fix critical bugs in channel connections
This commit introduces neighbourhood announcements which allows to maintaing neighbour map if each next-hop node. It also fixes a critical bug when accepting connections for a particular tunnel channel.
This commit is contained in:
31
network/proto/network.proto
Normal file
31
network/proto/network.proto
Normal file
@@ -0,0 +1,31 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package go.micro.network;
|
||||
|
||||
// Node is network node
|
||||
message Node {
|
||||
// node ide
|
||||
string id = 1;
|
||||
// node address
|
||||
string address = 2;
|
||||
}
|
||||
|
||||
// Connect is sent when the node connects to the network
|
||||
message Connect {
|
||||
// network mode
|
||||
Node node = 1;
|
||||
}
|
||||
|
||||
// Close is sent when the node disconnects from the network
|
||||
message Close {
|
||||
// network mode
|
||||
Node node = 1;
|
||||
}
|
||||
|
||||
// Neighbour is used to nnounce node neighbourhood
|
||||
message Neighbour {
|
||||
// network mode
|
||||
Node node = 1;
|
||||
// neighbours
|
||||
repeated Node neighbours = 3;
|
||||
}
|
||||
Reference in New Issue
Block a user