Documentation ¶
Index ¶
- func NewConcurrentQueryClient(mtx *tmsync.RWMutex, app types.Application) abcicli.Client
- func NewConcurrentQueryClientCreator(app types.Application) proxy.ClientCreator
- func NewMantlemintExecutor(db tmdb.DB, conn proxy.AppConnConsensus) *state.BlockExecutor
- type EventCollector
- func (ev *EventCollector) PublishEventNewBlock(block tm.EventDataNewBlock) error
- func (ev *EventCollector) PublishEventNewBlockHeader(_ tm.EventDataNewBlockHeader) error
- func (ev *EventCollector) PublishEventNewEvidence(_ tm.EventDataNewEvidence) error
- func (ev *EventCollector) PublishEventTx(txEvent tm.EventDataTx) error
- func (ev *EventCollector) PublishEventValidatorSetUpdates(_ tm.EventDataValidatorSetUpdates) error
- type Executor
- type Instance
- func (mm *Instance) GetCurrentBlock() *tendermint.Block
- func (mm *Instance) GetCurrentEventCollector() *EventCollector
- func (mm *Instance) GetCurrentHeight() int64
- func (mm *Instance) GetCurrentState() state.State
- func (mm *Instance) Init(genesis *tendermint.GenesisDoc) error
- func (mm *Instance) Inject(block *tendermint.Block) error
- func (mm *Instance) LoadInitialState() error
- func (mm *Instance) SetBlockExecutor(nextBlockExecutor Executor)
- type Mantlemint
- type MantlemintCallbackAfter
- type MantlemintCallbackBefore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewConcurrentQueryClient ¶
NewConcurrentQueryClient creates a local client, which will be directly calling the methods of the given app. + uses RWMutex for reads
func NewConcurrentQueryClientCreator ¶
func NewConcurrentQueryClientCreator(app types.Application) proxy.ClientCreator
func NewMantlemintExecutor ¶
func NewMantlemintExecutor( db tmdb.DB, conn proxy.AppConnConsensus, ) *state.BlockExecutor
NewMantlemintExecutor creates stock tendermint block executor, with stubbed mempool and evidence pool
Types ¶
type EventCollector ¶
type EventCollector struct { Height int64 Block *tm.Block ResponseBeginBlock *abci.ResponseBeginBlock ResponseEndBlock *abci.ResponseEndBlock ResponseDeliverTxs []*abci.ResponseDeliverTx }
func NewMantlemintEventCollector ¶
func NewMantlemintEventCollector() *EventCollector
func (*EventCollector) PublishEventNewBlock ¶
func (ev *EventCollector) PublishEventNewBlock( block tm.EventDataNewBlock, ) error
PublishEventNewBlock collects block, ResponseBeginBlock, ResponseEndBlock
func (*EventCollector) PublishEventNewBlockHeader ¶
func (ev *EventCollector) PublishEventNewBlockHeader( _ tm.EventDataNewBlockHeader, ) error
PublishEventNewBlockHeader unused
func (*EventCollector) PublishEventNewEvidence ¶
func (ev *EventCollector) PublishEventNewEvidence(_ tm.EventDataNewEvidence) error
PublishEventNewEvidence unused
func (*EventCollector) PublishEventTx ¶
func (ev *EventCollector) PublishEventTx( txEvent tm.EventDataTx, ) error
PublishEventTx collect txResult in order
func (*EventCollector) PublishEventValidatorSetUpdates ¶
func (ev *EventCollector) PublishEventValidatorSetUpdates( _ tm.EventDataValidatorSetUpdates, ) error
PublishEventValidatorSetUpdates unused
type Executor ¶
type Executor interface { ApplyBlock(state.State, tendermint.BlockID, *tendermint.Block) (state.State, int64, error) SetEventBus(publisher tendermint.BlockEventPublisher) }
type Instance ¶
type Instance struct {
// contains filtered or unexported fields
}
func (*Instance) GetCurrentBlock ¶
func (mm *Instance) GetCurrentBlock() *tendermint.Block
func (*Instance) GetCurrentEventCollector ¶
func (mm *Instance) GetCurrentEventCollector() *EventCollector
func (*Instance) GetCurrentHeight ¶
func (*Instance) GetCurrentState ¶
func (*Instance) Init ¶
func (mm *Instance) Init(genesis *tendermint.GenesisDoc) error
Init is port of ReplayBlocks() from tendermint, where it only handles initializing the chain.
func (*Instance) LoadInitialState ¶
func (*Instance) SetBlockExecutor ¶
type Mantlemint ¶
type Mantlemint interface { Inject(*tendermint.Block) error Init(*tendermint.GenesisDoc) error LoadInitialState() error GetCurrentHeight() int64 GetCurrentBlock() *tendermint.Block GetCurrentState() state.State GetCurrentEventCollector() *EventCollector SetBlockExecutor(executor Executor) }
func NewMantlemint ¶
func NewMantlemint( db tmdb.DB, conn proxy.AppConns, executor Executor, runBefore MantlemintCallbackBefore, runAfter MantlemintCallbackAfter, ) Mantlemint
type MantlemintCallbackAfter ¶
type MantlemintCallbackAfter func(block *tendermint.Block, events *EventCollector) error
type MantlemintCallbackBefore ¶
type MantlemintCallbackBefore func(block *tendermint.Block) error
Click to show internal directories.
Click to hide internal directories.