les: les/4 minimalistic version (#21909)
* les: allow tx unindexing in les/4 light server mode * les: minor fixes * les: more small fixes * les: add meaningful constants for recentTxIndex handshake field
This commit is contained in:
@ -1491,10 +1491,9 @@ func SetEthConfig(ctx *cli.Context, stack *node.Node, cfg *eth.Config) {
|
||||
CheckExclusive(ctx, LegacyLightServFlag, LightServeFlag, SyncModeFlag, "light")
|
||||
CheckExclusive(ctx, DeveloperFlag, ExternalSignerFlag) // Can't use both ephemeral unlocked and external signer
|
||||
CheckExclusive(ctx, GCModeFlag, "archive", TxLookupLimitFlag)
|
||||
// todo(rjl493456442) make it available for les server
|
||||
// Ancient tx indices pruning is not available for les server now
|
||||
// since light client relies on the server for transaction status query.
|
||||
CheckExclusive(ctx, LegacyLightServFlag, LightServeFlag, TxLookupLimitFlag)
|
||||
if (ctx.GlobalIsSet(LegacyLightServFlag.Name) || ctx.GlobalIsSet(LightServeFlag.Name)) && ctx.GlobalIsSet(TxLookupLimitFlag.Name) {
|
||||
log.Warn("LES server cannot serve old transaction status and cannot connect below les/4 protocol version if transaction lookup index is limited")
|
||||
}
|
||||
var ks *keystore.KeyStore
|
||||
if keystores := stack.AccountManager().Backends(keystore.KeyStoreType); len(keystores) > 0 {
|
||||
ks = keystores[0].(*keystore.KeyStore)
|
||||
|
Reference in New Issue
Block a user