mirror of
https://github.com/tendermint/tendermint.git
synced 2026-09-03 22:57:22 +00:00
blockchain/v1: remove in favor of v2 (#5728)
This commit is contained in:
@@ -30,7 +30,7 @@ var (
|
||||
nodeDatabases = uniformChoice{"goleveldb", "cleveldb", "rocksdb", "boltdb", "badgerdb"}
|
||||
nodeABCIProtocols = uniformChoice{"unix", "tcp", "grpc", "builtin"}
|
||||
nodePrivvalProtocols = uniformChoice{"file", "unix", "tcp"}
|
||||
nodeFastSyncs = uniformChoice{"", "v0", "v1", "v2"}
|
||||
nodeFastSyncs = uniformChoice{"", "v0", "v2"}
|
||||
nodeStateSyncs = uniformChoice{false, true}
|
||||
nodePersistIntervals = uniformChoice{0, 1, 5}
|
||||
nodeSnapshotIntervals = uniformChoice{0, 3}
|
||||
|
||||
@@ -73,7 +73,7 @@ perturb = ["kill", "pause", "disconnect", "restart"]
|
||||
[node.full01]
|
||||
start_at = 1010
|
||||
mode = "full"
|
||||
fast_sync = "v1"
|
||||
fast_sync = "v2"
|
||||
persistent_peers = ["validator01", "validator02", "validator03", "validator04", "validator05"]
|
||||
retain_blocks = 1
|
||||
perturb = ["restart"]
|
||||
|
||||
@@ -87,7 +87,7 @@ type ManifestNode struct {
|
||||
// runner will wait for the network to reach at least this block height.
|
||||
StartAt int64 `toml:"start_at"`
|
||||
|
||||
// FastSync specifies the fast sync mode: "" (disable), "v0", "v1", or "v2".
|
||||
// FastSync specifies the fast sync mode: "" (disable), "v0" or "v2".
|
||||
// Defaults to disabled.
|
||||
FastSync string `toml:"fast_sync"`
|
||||
|
||||
|
||||
@@ -307,7 +307,7 @@ func (n Node) Validate(testnet Testnet) error {
|
||||
}
|
||||
}
|
||||
switch n.FastSync {
|
||||
case "", "v0", "v1", "v2":
|
||||
case "", "v0", "v2":
|
||||
default:
|
||||
return fmt.Errorf("invalid fast sync setting %q", n.FastSync)
|
||||
}
|
||||
|
||||
@@ -20,7 +20,6 @@ import (
|
||||
|
||||
abci "github.com/tendermint/tendermint/abci/types"
|
||||
bcv0 "github.com/tendermint/tendermint/blockchain/v0"
|
||||
bcv1 "github.com/tendermint/tendermint/blockchain/v1"
|
||||
bcv2 "github.com/tendermint/tendermint/blockchain/v2"
|
||||
cfg "github.com/tendermint/tendermint/config"
|
||||
"github.com/tendermint/tendermint/consensus"
|
||||
@@ -157,7 +156,7 @@ func DefaultMetricsProvider(config *cfg.InstrumentationConfig) MetricsProvider {
|
||||
// Option sets a parameter for the node.
|
||||
type Option func(*Node)
|
||||
|
||||
// Temporary interface for switching to fast sync, we should get rid of v0 and v1 reactors.
|
||||
// Temporary interface for switching to fast sync, we should get rid of v0.
|
||||
// See: https://github.com/tendermint/tendermint/issues/4595
|
||||
type fastSyncReactor interface {
|
||||
SwitchToFastSync(sm.State) error
|
||||
@@ -408,8 +407,6 @@ func createBlockchainReactor(config *cfg.Config,
|
||||
switch config.FastSync.Version {
|
||||
case "v0":
|
||||
bcReactor = bcv0.NewBlockchainReactor(state.Copy(), blockExec, blockStore, fastSync)
|
||||
case "v1":
|
||||
bcReactor = bcv1.NewBlockchainReactor(state.Copy(), blockExec, blockStore, fastSync)
|
||||
case "v2":
|
||||
bcReactor = bcv2.NewBlockchainReactor(state.Copy(), blockExec, blockStore, fastSync)
|
||||
default:
|
||||
@@ -1280,8 +1277,6 @@ func makeNodeInfo(
|
||||
switch config.FastSync.Version {
|
||||
case "v0":
|
||||
bcChannel = bcv0.BlockchainChannel
|
||||
case "v1":
|
||||
bcChannel = bcv1.BlockchainChannel
|
||||
case "v2":
|
||||
bcChannel = bcv2.BlockchainChannel
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user