Versions in this module Expand all Collapse all v1 v1.0.0 Sep 1, 2023 Changes in this version + const MetricsSubsystem + var InitStateVersion = tmstate.Version + func ABCIResponsesResultsHash(ar *tmstate.ABCIResponses) []byte + func ExecCommitBlock(appConnConsensus proxy.AppConnConsensus, block *types.Block, logger log.Logger, ...) ([]byte, error) + func MakeGenesisDocFromFile(genDocFile string) (*types.GenesisDoc, error) + func MedianTime(commit *types.Commit, validators *types.ValidatorSet) time.Time + func Rollback(bs BlockStore, ss Store) (int64, []byte, error) + func TxPostCheck(state State) mempl.PostCheckFunc + func TxPreCheck(state State) mempl.PreCheckFunc + type BlockExecutor struct + func NewBlockExecutor(stateStore Store, logger log.Logger, proxyApp proxy.AppConnConsensus, ...) *BlockExecutor + func (blockExec *BlockExecutor) ApplyBlock(state State, blockID types.BlockID, block *types.Block) (State, int64, error) + func (blockExec *BlockExecutor) Commit(state State, block *types.Block, deliverTxResponses []*abci.ResponseDeliverTx) ([]byte, int64, error) + func (blockExec *BlockExecutor) CreateProposalBlock(height int64, state State, commit *types.Commit, proposerAddr []byte) (*types.Block, *types.PartSet) + func (blockExec *BlockExecutor) SetEventBus(eventBus types.BlockEventPublisher) + func (blockExec *BlockExecutor) Store() Store + func (blockExec *BlockExecutor) ValidateBlock(state State, block *types.Block) error + type BlockExecutorOption func(executor *BlockExecutor) + func BlockExecutorWithMetrics(metrics *Metrics) BlockExecutorOption + type BlockStore interface + Base func() int64 + Height func() int64 + LoadBaseMeta func() *types.BlockMeta + LoadBlock func(height int64) *types.Block + LoadBlockByHash func(hash []byte) *types.Block + LoadBlockCommit func(height int64) *types.Commit + LoadBlockMeta func(height int64) *types.BlockMeta + LoadBlockPart func(height int64, index int) *types.Part + LoadSeenCommit func(height int64) *types.Commit + PruneBlocks func(height int64) (uint64, error) + SaveBlock func(block *types.Block, blockParts *types.PartSet, seenCommit *types.Commit) + Size func() int64 + type EmptyEvidencePool struct + func (EmptyEvidencePool) AddEvidence(types.Evidence) error + func (EmptyEvidencePool) CheckEvidence(evList types.EvidenceList) error + func (EmptyEvidencePool) PendingEvidence(maxBytes int64) (ev []types.Evidence, size int64) + func (EmptyEvidencePool) ReportConflictingVotes(voteA, voteB *types.Vote) + func (EmptyEvidencePool) Update(State, types.EvidenceList) + type ErrAppBlockHeightTooHigh struct + AppHeight int64 + CoreHeight int64 + func (e ErrAppBlockHeightTooHigh) Error() string + type ErrAppBlockHeightTooLow struct + AppHeight int64 + StoreBase int64 + func (e ErrAppBlockHeightTooLow) Error() string + type ErrBlockHashMismatch struct + AppHash []byte + CoreHash []byte + Height int64 + func (e ErrBlockHashMismatch) Error() string + type ErrInvalidBlock error + type ErrLastStateMismatch struct + App []byte + Core []byte + Height int64 + func (e ErrLastStateMismatch) Error() string + type ErrNoABCIResponsesForHeight struct + Height int64 + func (e ErrNoABCIResponsesForHeight) Error() string + type ErrNoConsensusParamsForHeight struct + Height int64 + func (e ErrNoConsensusParamsForHeight) Error() string + type ErrNoValSetForHeight struct + Height int64 + func (e ErrNoValSetForHeight) Error() string + type ErrProxyAppConn error + type ErrStateMismatch struct + Expected *State + Got *State + func (e ErrStateMismatch) Error() string + type ErrUnknownBlock struct + Height int64 + func (e ErrUnknownBlock) Error() string + type EvidencePool interface + AddEvidence func(types.Evidence) error + CheckEvidence func(types.EvidenceList) error + PendingEvidence func(maxBytes int64) (ev []types.Evidence, size int64) + Update func(State, types.EvidenceList) + type Metrics struct + BlockProcessingTime metrics.Histogram + func NopMetrics() *Metrics + func PrometheusMetrics(namespace string, labelsAndValues ...string) *Metrics + type State struct + AppHash []byte + ChainID string + ConsensusParams tmproto.ConsensusParams + InitialHeight int64 + LastBlockHeight int64 + LastBlockID types.BlockID + LastBlockTime time.Time + LastHeightConsensusParamsChanged int64 + LastHeightValidatorsChanged int64 + LastResultsHash []byte + LastValidators *types.ValidatorSet + NextValidators *types.ValidatorSet + Validators *types.ValidatorSet + Version tmstate.Version + func MakeGenesisState(genDoc *types.GenesisDoc) (State, error) + func MakeGenesisStateFromFile(genDocFile string) (State, error) + func StateFromProto(pb *tmstate.State) (*State, error) + func (state *State) ToProto() (*tmstate.State, error) + func (state State) Bytes() []byte + func (state State) Copy() State + func (state State) Equals(state2 State) bool + func (state State) IsEmpty() bool + func (state State) MakeBlock(height int64, txs []types.Tx, commit *types.Commit, evidence []types.Evidence, ...) (*types.Block, *types.PartSet) + type Store interface + Bootstrap func(State) error + Load func() (State, error) + LoadABCIResponses func(int64) (*tmstate.ABCIResponses, error) + LoadConsensusParams func(int64) (tmproto.ConsensusParams, error) + LoadFromDBOrGenesisDoc func(*types.GenesisDoc) (State, error) + LoadFromDBOrGenesisFile func(string) (State, error) + LoadValidators func(int64) (*types.ValidatorSet, error) + PruneStates func(int64, int64) error + Save func(State) error + SaveABCIResponses func(int64, *tmstate.ABCIResponses) error + func NewStore(db dbm.DB) Store