micro/network/proto/network.proto
2019-07-03 19:26:24 +01:00

35 lines
710 B
Protocol Buffer

syntax = "proto3";
package go.micro.network;
// A connect message is for connecting to the network
message Connect {
// the unique muid (mac) address of the node
string muid = 1;
// Lease specifies an existing lease to indicate
// we don't need a new address, we just want to
// establish a link.
Lease lease = 2;
}
// A lease is returned to anyone attempting to connect with a valid muid.
message Lease {
// unique lease id
string id = 1;
// timestamp of lease
int64 timestamp = 2;
// author is the muid of the author
string author = 3;
// the node
Node node = 4;
}
// A node is the network node
message Node {
string muid = 1;
string id = 2;
string address = 3;
string network = 4;
}