Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement protocol test and boost bootstrapping by using cache #665

Merged
merged 18 commits into from Nov 25, 2019

Conversation

@limebell
Copy link
Contributor

limebell commented Nov 11, 2019

Previously protocol is tested with swarm, thus it is unsure whether the error is caused by network or protocol. Added ISwarm interface and TestSwarm which act like network, so cause of error is more clear.

Additionally, bootstrap procedure became faster by preventing peer to re-send FindNeighbors request to same peer.

@limebell limebell requested review from dahlia, longfin, earlbread and moreal Nov 11, 2019
@limebell limebell self-assigned this Nov 11, 2019
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch from fc2bb6b to 28301a5 Nov 11, 2019
@codecov

This comment has been minimized.

Copy link

codecov bot commented Nov 11, 2019

Codecov Report

Merging #665 into master will decrease coverage by 0.02%.
The diff coverage is 81.68%.

@@            Coverage Diff             @@
##           master     #665      +/-   ##
==========================================
- Coverage   86.15%   86.12%   -0.03%     
==========================================
  Files         218      221       +3     
  Lines       17750    18116     +366     
==========================================
+ Hits        15292    15603     +311     
- Misses       1395     1449      +54     
- Partials     1063     1064       +1
Impacted Files Coverage Δ
Libplanet/Net/Protocols/Kademlia.cs 94.11% <ø> (ø) ⬆️
Libplanet.Tests/Net/Protocols/RoutingTableTest.cs 100% <ø> (ø)
Libplanet/Net/Protocols/KBucket.cs 94.66% <100%> (ø) ⬆️
Libplanet.Tests/Net/SwarmTest.cs 95.73% <100%> (ø) ⬆️
Libplanet/Net/Messages/Message.cs 85.52% <100%> (ø) ⬆️
Libplanet.Tests/Net/Protocols/ProtocolTest.cs 100% <100%> (ø)
Libplanet/Net/Protocols/RoutingTable.cs 79% <100%> (+1.11%) ⬆️
Libplanet.Tests/Net/Protocols/TestMessage.cs 45.45% <45.45%> (ø)
Libplanet/Net/Protocols/KademliaProtocol.cs 66.41% <65.47%> (+1.02%) ⬆️
Libplanet.Tests/Net/Protocols/TestSwarm.cs 78.73% <78.73%> (ø)
... and 6 more
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch from 28301a5 to d0b253d Nov 13, 2019
CHANGES.md Outdated Show resolved Hide resolved
CHANGES.md Outdated Show resolved Hide resolved
CHANGES.md Outdated Show resolved Hide resolved
CHANGES.md Outdated Show resolved Hide resolved
Libplanet/Net/Swarm.cs Outdated Show resolved Hide resolved
Libplanet/Net/ISwarm.cs Outdated Show resolved Hide resolved
Libplanet.Tests/Net/Protocols/ProtocolTest.cs Outdated Show resolved Hide resolved
Libplanet.Tests/Net/Protocols/ProtocolTest.cs Outdated Show resolved Hide resolved
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch from 90ee9f1 to 06a4f8b Nov 13, 2019
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch from 06a4f8b to 4cfc966 Nov 13, 2019
Libplanet.Tests/Net/Protocols/TestSwarm.cs Outdated Show resolved Hide resolved
Libplanet.Tests/Net/Protocols/TestSwarm.cs Outdated Show resolved Hide resolved
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch 3 times, most recently from 29d64ef to b92a66b Nov 13, 2019
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch 5 times, most recently from e3bd7dd to c1a6a3d Nov 13, 2019
@limebell limebell changed the title Implement protocol test Implement protocol test and boost bootstrapping by using cache Nov 19, 2019
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch 2 times, most recently from c33d14b to a452888 Nov 19, 2019
@limebell limebell dismissed stale reviews from earlbread and longfin via e25b9a6 Nov 21, 2019
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch from 128c551 to e25b9a6 Nov 21, 2019
Libplanet/Net/Protocols/KBucket.cs Outdated Show resolved Hide resolved
Libplanet/Net/Protocols/KademliaProtocol.cs Outdated Show resolved Hide resolved
Libplanet/Net/Protocols/KademliaProtocol.cs Outdated Show resolved Hide resolved
@limebell limebell force-pushed the limebell:atomic-kademlia-test branch from e25b9a6 to feb68ad Nov 21, 2019
@limebell limebell merged commit 3597c5a into planetarium:master Nov 25, 2019
19 of 20 checks passed
19 of 20 checks passed
benchmarks (macos-latest)
Details
dist
Details
benchmarks (ubuntu-18.04)
Details
benchmarks (windows-latest)
Details
docs
Details
codecov/patch 81.68% of diff hit (target 86.15%)
Details
WIP Ready for review
Details
changelog This contains self-describing changelog.
Details
codecov/project 86.12% (-0.03%) compared to 1f7cc1b
Details
license/cla Contributor License Agreement is signed.
Details
planetarium.libplanet Build #20191125.1 had test failures
Details
planetarium.libplanet (Linux_Mono) Linux_Mono succeeded
Details
planetarium.libplanet (Linux_NETCore) Linux_NETCore succeeded
Details
planetarium.libplanet (Windows_Mono) Windows_Mono succeeded
Details
planetarium.libplanet (Windows_NETCore) Windows_NETCore succeeded
Details
planetarium.libplanet (Windows_NETCore_coverage) Windows_NETCore_coverage succeeded
Details
planetarium.libplanet (Windows_NETFramework) Windows_NETFramework succeeded
Details
planetarium.libplanet (macOS_Mono) macOS_Mono succeeded
Details
planetarium.libplanet (macOS_NETCore) macOS_NETCore succeeded
Details
planetarium.libplanet (macOS_Unity) macOS_Unity succeeded
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.