cmd: no need to check txlookup limit in archive node

Signed-off-by: Delweng <delweng@gmail.com>
This commit is contained in:
Delweng 2025-06-27 16:03:51 +08:00
parent 3f3ac943ac
commit db92f7caee

View file

@ -1656,12 +1656,6 @@ func SetEthConfig(ctx *cli.Context, stack *node.Node, cfg *ethconfig.Config) {
log.Warn("The flag --txlookuplimit is deprecated and will be removed, please use --history.transactions") log.Warn("The flag --txlookuplimit is deprecated and will be removed, please use --history.transactions")
cfg.TransactionHistory = ctx.Uint64(TxLookupLimitFlag.Name) cfg.TransactionHistory = ctx.Uint64(TxLookupLimitFlag.Name)
} }
if ctx.String(GCModeFlag.Name) == "archive" {
if cfg.TransactionHistory != 0 {
cfg.TransactionHistory = 0
log.Warn("Disabled transaction unindexing for archive node")
}
}
if ctx.IsSet(LogHistoryFlag.Name) { if ctx.IsSet(LogHistoryFlag.Name) {
cfg.LogHistory = ctx.Uint64(LogHistoryFlag.Name) cfg.LogHistory = ctx.Uint64(LogHistoryFlag.Name)
} }