mirror of
https://github.com/tendermint/tendermint.git
synced 2026-01-10 06:57:24 +00:00
This PR makes vote extensions optional within Tendermint. A new ConsensusParams field, called ABCIParams.VoteExtensionsEnableHeight, has been added to toggle whether or not extensions should be enabled or disabled depending on the current height of the consensus engine. Related to: #8453
24 lines
610 B
Go
24 lines
610 B
Go
package factory
|
|
|
|
import (
|
|
"time"
|
|
|
|
"github.com/tendermint/tendermint/types"
|
|
)
|
|
|
|
// ConsensusParams returns a default set of ConsensusParams that are suitable
|
|
// for use in testing
|
|
func ConsensusParams() *types.ConsensusParams {
|
|
c := types.DefaultConsensusParams()
|
|
c.Timeout = types.TimeoutParams{
|
|
Commit: 10 * time.Millisecond,
|
|
Propose: 40 * time.Millisecond,
|
|
ProposeDelta: 1 * time.Millisecond,
|
|
Vote: 10 * time.Millisecond,
|
|
VoteDelta: 1 * time.Millisecond,
|
|
BypassCommitTimeout: true,
|
|
}
|
|
c.ABCI.VoteExtensionsEnableHeight = 1
|
|
return c
|
|
}
|