Files
tendermint/version/version.go
Erik Grinaker 569981325a add ABCI interface for state sync snapshots (#4704)
Adds the ABCI interface for [state sync](https://github.com/tendermint/tendermint/issues/828) as outlined in [ADR-053](https://github.com/tendermint/tendermint/blob/master/docs/architecture/adr-053-state-sync-prototype.md), and bumps ABCIVersion to `0.17.0`.

The interface adds a new ABCI connection which Tendermint can use to query and load snapshots from the app (for serving snapshots to other nodes), and to offer and apply snapshots to the app (for state syncing a local node from peers).

Split out from the original PR in #4645, state sync reactor will be submitted as a separate PR. The interface is implemented by the Cosmos SDK in https://github.com/cosmos/cosmos-sdk/pull/5803.
2020-04-29 10:32:09 +02:00

67 lines
1.8 KiB
Go

package version
var (
// GitCommit is the current HEAD set using ldflags.
GitCommit string
// Version is the built softwares version.
Version = TMCoreSemVer
)
func init() {
if GitCommit != "" {
Version += "-" + GitCommit
}
}
const (
// TMCoreSemVer is the current version of Tendermint Core.
// It's the Semantic Version of the software.
// Must be a string because scripts like dist.sh read this file.
// XXX: Don't change the name of this variable or you will break
// automation :)
TMCoreSemVer = "0.33.4"
// ABCISemVer is the semantic version of the ABCI library
ABCISemVer = "0.17.0"
ABCIVersion = ABCISemVer
)
// Protocol is used for implementation agnostic versioning.
type Protocol uint64
// Uint64 returns the Protocol version as a uint64,
// eg. for compatibility with ABCI types.
func (p Protocol) Uint64() uint64 {
return uint64(p)
}
var (
// P2PProtocol versions all p2p behaviour and msgs.
// This includes proposer selection.
P2PProtocol Protocol = 7
// BlockProtocol versions all block data structures and processing.
// This includes validity of blocks and state updates.
BlockProtocol Protocol = 10
)
//------------------------------------------------------------------------
// Version types
// App includes the protocol and software version for the application.
// This information is included in ResponseInfo. The App.Protocol can be
// updated in ResponseEndBlock.
type App struct {
Protocol Protocol `json:"protocol"`
Software string `json:"software"`
}
// Consensus captures the consensus rules for processing a block in the blockchain,
// including all blockchain data structures and the rules of the application's
// state transition machine.
type Consensus struct {
Block Protocol `json:"block"`
App Protocol `json:"app"`
}