netzwerk
is a library, that lets you build peer-to-peer (p2p) nodes, and which is:
To run a minimal "pingpong" example open two terminals and enter the following two commands respectively.
cargo r --example pingpong -- --bind localhost:1337 --peers tcp://localhost:1338 --msg ping
cargo r --example pingpong -- --bind localhost:1338 --peers tcp://localhost:1337 --msg pong
Do not use this crate for any serious application. This is just a prototype for another project.