Remove Disable DiscoveryV5 Flag (#11237)

* remove flag

* go fmt

Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
This commit is contained in:
Nishant Das
2022-08-17 20:45:12 +08:00
committed by GitHub
parent a9ccabf6c9
commit 25d87dd27b
7 changed files with 1 additions and 12 deletions

View File

@@ -551,7 +551,6 @@ func (b *BeaconNode) registerP2P(cliCtx *cli.Context) error {
AllowListCIDR: cliCtx.String(cmd.P2PAllowList.Name),
DenyListCIDR: slice.SplitCommaSeparated(cliCtx.StringSlice(cmd.P2PDenyList.Name)),
EnableUPnP: cliCtx.Bool(cmd.EnableUPnPFlag.Name),
DisableDiscv5: cliCtx.Bool(flags.DisableDiscv5.Name),
StateNotifier: b,
DB: b.db,
})

View File

@@ -10,7 +10,6 @@ import (
type Config struct {
NoDiscovery bool
EnableUPnP bool
DisableDiscv5 bool
StaticPeers []string
BootstrapNodeAddr []string
Discv5BootStrapAddr []string

View File

@@ -201,7 +201,7 @@ func (s *Service) Start() {
}
}
if !s.cfg.NoDiscovery && !s.cfg.DisableDiscv5 {
if !s.cfg.NoDiscovery {
ipAddr := prysmnetwork.IPAddr()
listener, err := s.startDiscoveryV5(
ipAddr,

View File

@@ -142,11 +142,6 @@ var (
Usage: "The slot durations of when an archived state gets saved in the beaconDB.",
Value: 2048,
}
// DisableDiscv5 disables running discv5.
DisableDiscv5 = &cli.BoolFlag{
Name: "disable-discv5",
Usage: "Does not run the discoveryV5 dht.",
}
// BlockBatchLimit specifies the requested block batch size.
BlockBatchLimit = &cli.IntFlag{
Name: "block-batch-limit",

View File

@@ -8,7 +8,6 @@ import (
// GlobalFlags specifies all the global flags for the
// beacon node.
type GlobalFlags struct {
DisableDiscv5 bool
SubscribeToAllSubnets bool
MinimumSyncPeers int
MinimumPeersPerSubnet int
@@ -39,7 +38,6 @@ func ConfigureGlobalFlags(ctx *cli.Context) {
log.Warn("Subscribing to All Attestation Subnets")
cfg.SubscribeToAllSubnets = true
}
cfg.DisableDiscv5 = ctx.Bool(DisableDiscv5.Name)
cfg.BlockBatchLimit = ctx.Int(BlockBatchLimit.Name)
cfg.BlockBatchLimitBurstFactor = ctx.Int(BlockBatchLimitBurstFactor.Name)
cfg.MinimumPeersPerSubnet = ctx.Int(MinPeersPerSubnet.Name)

View File

@@ -51,7 +51,6 @@ var appFlags = []cli.Flag{
flags.MinSyncPeers,
flags.ContractDeploymentBlock,
flags.SetGCPercent,
flags.DisableDiscv5,
flags.BlockBatchLimit,
flags.BlockBatchLimitBurstFactor,
flags.InteropMockEth1DataVotesFlag,

View File

@@ -110,7 +110,6 @@ var appHelpFlagGroups = []flagGroup{
flags.ExecutionJWTSecretFlag,
flags.SetGCPercent,
flags.SlotsPerArchivedPoint,
flags.DisableDiscv5,
flags.BlockBatchLimit,
flags.BlockBatchLimitBurstFactor,
flags.EnableDebugRPCEndpoints,