|
|
@ -813,13 +813,23 @@ type ConsensusConfig struct { |
|
|
|
WalPath string `mapstructure:"wal_file"` |
|
|
|
walFile string // overrides WalPath if set
|
|
|
|
|
|
|
|
TimeoutPropose time.Duration `mapstructure:"timeout_propose"` |
|
|
|
TimeoutProposeDelta time.Duration `mapstructure:"timeout_propose_delta"` |
|
|
|
TimeoutPrevote time.Duration `mapstructure:"timeout_prevote"` |
|
|
|
TimeoutPrevoteDelta time.Duration `mapstructure:"timeout_prevote_delta"` |
|
|
|
TimeoutPrecommit time.Duration `mapstructure:"timeout_precommit"` |
|
|
|
// How long we wait for a proposal block before prevoting nil
|
|
|
|
TimeoutPropose time.Duration `mapstructure:"timeout_propose"` |
|
|
|
// How much timeout_propose increases with each round
|
|
|
|
TimeoutProposeDelta time.Duration `mapstructure:"timeout_propose_delta"` |
|
|
|
// How long we wait after receiving +2/3 prevotes for “anything” (ie. not a single block or nil)
|
|
|
|
TimeoutPrevote time.Duration `mapstructure:"timeout_prevote"` |
|
|
|
// How much the timeout_prevote increases with each round
|
|
|
|
TimeoutPrevoteDelta time.Duration `mapstructure:"timeout_prevote_delta"` |
|
|
|
// How long we wait after receiving +2/3 precommits for “anything” (ie. not a single block or nil)
|
|
|
|
TimeoutPrecommit time.Duration `mapstructure:"timeout_precommit"` |
|
|
|
// How much the timeout_precommit increases with each round
|
|
|
|
TimeoutPrecommitDelta time.Duration `mapstructure:"timeout_precommit_delta"` |
|
|
|
TimeoutCommit time.Duration `mapstructure:"timeout_commit"` |
|
|
|
// How long we wait after committing a block, before starting on the new
|
|
|
|
// height (this gives us a chance to receive some more precommits, even
|
|
|
|
// though we already have +2/3).
|
|
|
|
// NOTE: when modifying, make sure to update time_iota_ms genesis parameter
|
|
|
|
TimeoutCommit time.Duration `mapstructure:"timeout_commit"` |
|
|
|
|
|
|
|
// Make progress as soon as we have all the precommits (as if TimeoutCommit = 0)
|
|
|
|
SkipTimeoutCommit bool `mapstructure:"skip_timeout_commit"` |
|
|
@ -864,6 +874,7 @@ func TestConsensusConfig() *ConsensusConfig { |
|
|
|
cfg.TimeoutPrevoteDelta = 1 * time.Millisecond |
|
|
|
cfg.TimeoutPrecommit = 10 * time.Millisecond |
|
|
|
cfg.TimeoutPrecommitDelta = 1 * time.Millisecond |
|
|
|
// NOTE: when modifying, make sure to update time_iota_ms (testGenesisFmt) in toml.go
|
|
|
|
cfg.TimeoutCommit = 10 * time.Millisecond |
|
|
|
cfg.SkipTimeoutCommit = true |
|
|
|
cfg.PeerGossipSleepDuration = 5 * time.Millisecond |
|
|
|