-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Continuation of the epic for `alpha test` command. In this PR are included: - Start of TCP libp2p node. - Connection to other peer nodes (using hash of the ENRs as an ID for the relay). - Launching 3 ping tests towards peers: - Ping - regular ping done only once. It blocks the rest of the peer tests. We assume that if we cannot successfully ping a peer, there is no reason to execute any other tests against that peer. - PingMeasure - regular ping done only once, measuring the RTT. RTT is considered either good, average or bad. - PingLoad - continuous pings, spawning each second a new go routine doing pings, measuring the RTT of each one of them. The RTT is considered either good, average or bad. Worst observed RTT is picked as a resulting value. - Keeping the TCP node alive (configurable by a flag), in order other peers to be able to conduct tests on their end. N.B.: There are some hardcoded values that are subject to change: - Threshold for good/average/bad for PingMeasure test (currently set to 200/500ms); - Threshold for good/average/bad for PingLoad test (currently set to 200/500ms); - Await time between ping attempts in Ping test, when peer is not reachable (currently set to 3s); - Await time between pings in PingLoad test per go routine (currently set to random value between 0 and 100ms); Not in scope of this PR: - Tests against self - More elaborate tests towards peers - direct/indirect connections, packet loss, etc. category: feature ticket: #2997
- Loading branch information
1 parent
ff6a69b
commit 21d34cc
Showing
7 changed files
with
538 additions
and
271 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.