Add a substrate-peerset crate (#2042)

* Add a substrate-peerset crate

* Some adjustements

* More adjustements

* Use a temporary libp2p branch

* Add back-off mechanism

* Fix RPC tests

* Some adjustements

* Another libp2p bugfix

* Do a round-robin in the peerset

* Use a real dependency instead of a patch for libp2p

* Initialize reserved nodes correctly

* Better diagnostic for no address

* Don't allocate slots if in reserved only

* Ban node on dial failure

* Fix indentation
This commit is contained in:
Pierre Krieger
2019-03-21 14:02:28 +01:00
committed by Robert Habermeier
parent f6f15b618e
commit 90c6f85db5
17 changed files with 1255 additions and 1517 deletions
+1
View File
@@ -27,6 +27,7 @@ client = { package = "substrate-client", path = "../../core/client" }
runtime_primitives = { package = "sr-primitives", path = "../../core/sr-primitives" }
parity-codec = { version = "3.2", features = ["derive"] }
network_libp2p = { package = "substrate-network-libp2p", path = "../../core/network-libp2p" }
peerset = { package = "substrate-peerset", path = "../../core/peerset" }
tokio = "0.1.11"
keyring = { package = "substrate-keyring", path = "../../core/keyring", optional = true }
test_client = { package = "substrate-test-client", path = "../../core/test-client", optional = true }