-
Notifications
You must be signed in to change notification settings - Fork 370
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
feat: clean up p2p
& implement bootnode (seed
peers) support
#2852
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2852 +/- ##
==========================================
- Coverage 60.91% 60.91% -0.01%
==========================================
Files 564 563 -1
Lines 75267 74494 -773
==========================================
- Hits 45849 45375 -474
+ Misses 26047 25782 -265
+ Partials 3371 3337 -34
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
seed
peers) supportp2p
& implement bootnode (seed
peers) support
@@ -12,7 +12,7 @@ import ( | |||
"github.com/gnolang/gno/tm2/pkg/bft/types" | |||
"github.com/gnolang/gno/tm2/pkg/flow" | |||
"github.com/gnolang/gno/tm2/pkg/log" | |||
"github.com/gnolang/gno/tm2/pkg/p2p" | |||
types2 "github.com/gnolang/gno/tm2/pkg/p2p" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The import name seems strange to me. Does it mean something I missed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -36,10 +26,10 @@ type P2PConfig struct { | |||
UPNP bool `json:"upnp" toml:"upnp" comment:"UPNP port forwarding"` | |||
|
|||
// Maximum number of inbound peers | |||
MaxNumInboundPeers int `json:"max_num_inbound_peers" toml:"max_num_inbound_peers" comment:"Maximum number of inbound peers"` | |||
MaxNumInboundPeers uint64 `json:"max_num_inbound_peers" toml:"max_num_inbound_peers" comment:"Maximum number of inbound peers"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unsigned may be better than signed if we don't need to use patterns like -1
. However, since we're constrained by the OS limits, a size of 64 may be excessive.
Description
This PR introduces bootnode (
seed
mode) support for TM2 peering, and cleans up parts of thep2p
module codebase.Closes #2308
Contributors' checklist...
BREAKING CHANGE: xxx
message was included in the description