mirror of
https://github.com/tendermint/tendermint.git
synced 2026-01-08 22:23:11 +00:00
rename configuration parameters to use the new blocksync nomenclature (#6896)
The 0.35 release cycle renamed the 'fastsync' functionality to 'blocksync'. This change brings the configuration parameters in line with that change. Namely, it updates the configuration file `[fastsync]` field to be `[blocksync]` and changes the command line flag and config file parameters `--fast-sync` and `fast-sync` to `--enable-block-sync` and `enable-block-sync` respectively. Error messages were added to help users encountering these changes be able to quickly make the needed update to their files/scripts. When using the old command line argument for fast-sync, the following is printed ``` ./build/tendermint start --proxy-app=kvstore --consensus.create-empty-blocks=false --fast-sync=false ERROR: invalid argument "false" for "--fast-sync" flag: --fast-sync has been deprecated, please use --enable-block-sync ``` When using one of the old config file parameters, the following is printed: ``` ./build/tendermint start --proxy-app=kvstore --consensus.create-empty-blocks=false ERROR: error in config file: a configuration parameter named 'fast-sync' was found in the configuration file. The 'fast-sync' parameter has been renamed to 'enable-block-sync', please update the 'fast-sync' field in your configuration file to 'enable-block-sync' ```
This commit is contained in:
@@ -220,7 +220,7 @@ func makeNode(config *cfg.Config,
|
||||
|
||||
// Determine whether we should do block sync. This must happen after the handshake, since the
|
||||
// app may modify the validator set, specifying ourself as the only validator.
|
||||
blockSync := config.FastSyncMode && !onlyValidatorIsUs(state, pubKey)
|
||||
blockSync := config.BlockSync.Enable && !onlyValidatorIsUs(state, pubKey)
|
||||
|
||||
logNodeStartupInfo(state, pubKey, logger, consensusLogger, config.Mode)
|
||||
|
||||
@@ -716,7 +716,7 @@ func (n *nodeImpl) OnStart() error {
|
||||
// TODO: Some form of orchestrator is needed here between the state
|
||||
// advancing reactors to be able to control which one of the three
|
||||
// is running
|
||||
if n.config.FastSyncMode {
|
||||
if n.config.BlockSync.Enable {
|
||||
// FIXME Very ugly to have these metrics bleed through here.
|
||||
n.consensusReactor.SetBlockSyncingMetrics(1)
|
||||
if err := bcR.SwitchToBlockSync(state); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user