prysm-pulse/shared/featureconfig/flags.go
Preston Van Loon 0481eb4872
Track finalized block root index and filter in blocks by range (#3873)
* checkpoint progress

* feature flag and test

* return true if feature flag is not on

* add lint msg

* rollback tx if failure

* Revert validator/BUILD.bazel
2019-10-29 11:14:17 -04:00

91 lines
3.5 KiB
Go

package featureconfig
import (
"github.com/urfave/cli"
)
var (
// GenesisDelayFlag disables the standard genesis delay.
GenesisDelayFlag = cli.BoolFlag{
Name: "genesis-delay",
Usage: "Wait and process the genesis event at the midnight of the next day rather than 30s after the ETH1 block time of the chainstart triggering deposit",
}
// MinimalConfigFlag enables the minimal configuration.
MinimalConfigFlag = cli.BoolFlag{
Name: "minimal-config",
Usage: "Use minimal config with parameters as defined in the spec.",
}
writeSSZStateTransitionsFlag = cli.BoolFlag{
Name: "interop-write-ssz-state-transitions",
Usage: "Write ssz states to disk after attempted state transition",
}
// EnableAttestationCacheFlag see https://github.com/prysmaticlabs/prysm/issues/3106.
EnableAttestationCacheFlag = cli.BoolFlag{
Name: "enable-attestation-cache",
Usage: "Enable unsafe cache mechanism. See https://github.com/prysmaticlabs/prysm/issues/3106",
}
// EnableEth1DataVoteCacheFlag see https://github.com/prysmaticlabs/prysm/issues/3106.
EnableEth1DataVoteCacheFlag = cli.BoolFlag{
Name: "enable-eth1-data-vote-cache",
Usage: "Enable unsafe cache mechanism. See https://github.com/prysmaticlabs/prysm/issues/3106",
}
// InitSyncNoVerifyFlag enables the initial sync no verify configuration.
InitSyncNoVerifyFlag = cli.BoolFlag{
Name: "init-sync-no-verify",
Usage: "Initial sync to finalized check point w/o verifying block's signature, RANDAO and attestation's aggregated signatures",
}
// NewCacheFlag enables the node to use the new caching scheme.
NewCacheFlag = cli.BoolFlag{
Name: "new-cache",
Usage: "Use the new shuffled indices cache for committee. Much improvement than previous caching implementations",
}
// SkipBLSVerifyFlag skips BLS signature verification across the runtime for development purposes.
SkipBLSVerifyFlag = cli.BoolFlag{
Name: "skip-bls-verify",
Usage: "Whether or not to skip BLS verification of signature at runtime, this is unsafe and should only be used for development",
}
enableBackupWebhookFlag = cli.BoolFlag{
Name: "enable-db-backup-webhook",
Usage: "Serve HTTP handler to initiate database backups. The handler is served on the monitoring port at path /db/backup.",
}
enableBLSPubkeyCacheFlag = cli.BoolFlag{
Name: "enable-bls-pubkey-cache",
Usage: "Enable BLS pubkey cache to improve wall time of PubkeyFromBytes",
}
// OptimizeProcessEpoch optimizes process epoch.
OptimizeProcessEpoch = cli.BoolFlag{
Name: "optimize-process-epoch",
Usage: "Process epoch with optimizations",
}
pruneFinalizedStatesFlag = cli.BoolFlag{
Name: "prune-finalized-states",
Usage: "Delete old states from the database after reaching new finalized checkpoint",
}
enableFinalizedBlockRootIndexFlag = cli.BoolFlag{
Name: "enable-finalized-block-root-index",
Usage: "Enable tracking finalized block roots in database index.",
}
)
// ValidatorFlags contains a list of all the feature flags that apply to the validator client.
var ValidatorFlags = []cli.Flag{
MinimalConfigFlag,
}
// BeaconChainFlags contains a list of all the feature flags that apply to the beacon-chain client.
var BeaconChainFlags = []cli.Flag{
GenesisDelayFlag,
MinimalConfigFlag,
writeSSZStateTransitionsFlag,
EnableAttestationCacheFlag,
EnableEth1DataVoteCacheFlag,
InitSyncNoVerifyFlag,
NewCacheFlag,
SkipBLSVerifyFlag,
OptimizeProcessEpoch,
enableBackupWebhookFlag,
enableBLSPubkeyCacheFlag,
pruneFinalizedStatesFlag,
enableFinalizedBlockRootIndexFlag,
}