OpenAtomFoundation / xupercore

The kernel of xuperchain.
Apache License 2.0
61 stars 47 forks source link

p2pv1: change dynamic-nodes connections to static-node connections in static-node mode. #230

Closed aucusaga closed 3 years ago

aucusaga commented 3 years ago

Description

Add router in static-node mode.

Fixes # (issue)

Type of change

Brief of your solution

Nodes can refresh their router info by the function GetPeerInfo.

How Has This Been Tested?

Use testnet and xfront.

codecov-commenter commented 3 years ago

Codecov Report

Merging #230 (6acc077) into master (7bf2eb8) will increase coverage by 0.18%. The diff coverage is 61.11%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #230      +/-   ##
==========================================
+ Coverage   47.33%   47.51%   +0.18%     
==========================================
  Files         133      133              
  Lines       11411    11455      +44     
==========================================
+ Hits         5401     5443      +42     
  Misses       4876     4876              
- Partials     1134     1136       +2     
Impacted Files Coverage Δ
bcs/network/p2pv1/client.go 46.09% <0.00%> (-3.03%) :arrow_down:
bcs/network/p2pv1/conn.go 53.19% <33.33%> (-1.65%) :arrow_down:
bcs/network/p2pv1/server.go 57.85% <50.00%> (+0.03%) :arrow_up:
bcs/network/p2pv1/handler.go 80.35% <93.75%> (+13.69%) :arrow_up:
bcs/network/p2pv1/filter.go 85.18% <100.00%> (ø)
kernel/consensus/base/driver/chained-bft/smr.go 49.53% <0.00%> (-0.93%) :arrow_down:
bcs/consensus/tdpos/tdpos.go 40.96% <0.00%> (+0.80%) :arrow_up:
bcs/ledger/xledger/ledger/ledger.go 56.82% <0.00%> (+0.97%) :arrow_up:
bcs/consensus/tdpos/common.go 67.18% <0.00%> (+3.12%) :arrow_up:
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 7bf2eb8...6acc077. Read the comment docs.