cmd, eth: offer maxprice flag for overwritting price cap (#21531)
* cmd, eth: offer maxprice flag for overwritting price cap * eth: rename default price cap
This commit is contained in:
@ -631,6 +631,11 @@ var (
|
||||
Usage: "Suggested gas price is the given percentile of a set of recent transaction gas prices",
|
||||
Value: eth.DefaultConfig.GPO.Percentile,
|
||||
}
|
||||
GpoMaxGasPriceFlag = cli.Int64Flag{
|
||||
Name: "gpo.maxprice",
|
||||
Usage: "Maximum gas price will be recommended by gpo",
|
||||
Value: eth.DefaultConfig.GPO.MaxPrice.Int64(),
|
||||
}
|
||||
WhisperEnabledFlag = cli.BoolFlag{
|
||||
Name: "shh",
|
||||
Usage: "Enable Whisper",
|
||||
@ -1291,6 +1296,9 @@ func setGPO(ctx *cli.Context, cfg *gasprice.Config, light bool) {
|
||||
if ctx.GlobalIsSet(GpoPercentileFlag.Name) {
|
||||
cfg.Percentile = ctx.GlobalInt(GpoPercentileFlag.Name)
|
||||
}
|
||||
if ctx.GlobalIsSet(GpoMaxGasPriceFlag.Name) {
|
||||
cfg.MaxPrice = big.NewInt(ctx.GlobalInt64(GpoMaxGasPriceFlag.Name))
|
||||
}
|
||||
}
|
||||
|
||||
func setTxPool(ctx *cli.Context, cfg *core.TxPoolConfig) {
|
||||
|
Reference in New Issue
Block a user