Skip to content

Commit

Permalink
Remove --sync.loop.prune.limit flag (#12051)
Browse files Browse the repository at this point in the history
  • Loading branch information
AskAlexSharov authored Sep 20, 2024
1 parent 7ddca95 commit 23b46fa
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 17 deletions.
2 changes: 0 additions & 2 deletions eth/ethconfig/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ var Defaults = Config{
BodyCacheLimit: 256 * 1024 * 1024,
BodyDownloadTimeoutSeconds: 2,
//LoopBlockLimit: 100_000,
PruneLimit: 100,
ParallelStateFlushing: true,
},
Ethash: ethashcfg.Config{
Expand Down Expand Up @@ -270,7 +269,6 @@ type Sync struct {

BodyCacheLimit datasize.ByteSize
BodyDownloadTimeoutSeconds int // TODO: change to duration
PruneLimit int //the maximum records to delete from the DB during pruning
BreakAfterStage string
LoopBlockLimit uint
ParallelStateFlushing bool
Expand Down
4 changes: 0 additions & 4 deletions turbo/app/snapshots_cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,6 @@ var snapshotCommand = cli.Command{
ctx.Set(erigoncli.FrozenBlockLimitFlag.Name, "1500000")
}

if !ctx.IsSet(erigoncli.SyncLoopPruneLimitFlag.Name) {
ctx.Set(erigoncli.SyncLoopPruneLimitFlag.Name, "100000")
}

return nil
},
},
Expand Down
1 change: 0 additions & 1 deletion turbo/cli/default_flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,5 @@ var DefaultFlags = []cli.Flag{
&utils.TxPoolGossipDisableFlag,
&SyncLoopBlockLimitFlag,
&SyncLoopBreakAfterFlag,
&SyncLoopPruneLimitFlag,
&SyncParallelStateFlushing,
}
10 changes: 0 additions & 10 deletions turbo/cli/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,12 +138,6 @@ var (
Value: "",
}

SyncLoopPruneLimitFlag = cli.UintFlag{
Name: "sync.loop.prune.limit",
Usage: "Sets the maximum number of block to prune per loop iteration",
Value: 100,
}

SyncLoopBreakAfterFlag = cli.StringFlag{
Name: "sync.loop.break.after",
Usage: "Sets the last stage of the sync loop to run",
Expand Down Expand Up @@ -349,10 +343,6 @@ func ApplyFlagsForEthConfig(ctx *cli.Context, cfg *ethconfig.Config, logger log.
cfg.Sync.LoopThrottle = syncLoopThrottle
}

if limit := ctx.Uint(SyncLoopPruneLimitFlag.Name); limit > 0 {
cfg.Sync.PruneLimit = int(limit)
}

if stage := ctx.String(SyncLoopBreakAfterFlag.Name); len(stage) > 0 {
cfg.Sync.BreakAfterStage = stage
}
Expand Down

0 comments on commit 23b46fa

Please sign in to comment.