use peer center instance to gatter peers info (#21)

* use peer center instance to gatter peers info
This commit is contained in:
Sijie.Sun
2024-02-29 00:04:48 +08:00
committed by GitHub
parent 31af413b03
commit 24178bcf6e
8 changed files with 291 additions and 65 deletions

View File

@@ -92,6 +92,9 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
tonic_build::configure()
.type_attribute(".", "#[derive(serde::Serialize, serde::Deserialize)]")
.type_attribute("cli.DirectConnectedPeerInfo", "#[derive(Hash)]")
.type_attribute("cli.PeerInfoForGlobalMap", "#[derive(Hash)]")
.btree_map(&["."])
.compile(&["proto/cli.proto"], &["proto/"])
.unwrap();
// tonic_build::compile_protos("proto/cli.proto")?;