Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PreBlockHandler ¶
type PreBlockHandler struct {
// contains filtered or unexported fields
}
PreBlockHandler is responsible for aggregating oracle data from each validator and writing the oracle data into the store before any transactions are executed/finalized for a given block.
func NewOraclePreBlockHandler ¶
func NewOraclePreBlockHandler( logger log.Logger, aggregateFn aggregator.AggregateFnFromContext[string, map[connecttypes.CurrencyPair]*big.Int], oracleKeeper connectabcitypes.OracleKeeper, metrics servicemetrics.Metrics, strategy currencypair.CurrencyPairStrategy, veCodec codec.VoteExtensionCodec, ecCodec codec.ExtendedCommitCodec, ) *PreBlockHandler
NewOraclePreBlockHandler returns a new PreBlockHandler. The handler is responsible for writing oracle data included in vote extensions to state.
func (*PreBlockHandler) PreBlocker
deprecated
func (h *PreBlockHandler) PreBlocker() sdk.PreBlocker
PreBlocker is called by the base app before the block is finalized. It is responsible for aggregating oracle data from each validator and writing the oracle data to the store.
Deprecated: using PreBlocker requires wrapping module Manager's PreBlock call. This method should no longer be used. Use WrappedPreBlocker instead to handle this functionality automatically.
func (*PreBlockHandler) WrappedPreBlocker ¶
func (h *PreBlockHandler) WrappedPreBlocker(mm *module.Manager) sdk.PreBlocker
WrappedPreBlocker is called by the base app before the block is finalized. It is responsible for calling the module manager's PreBlock method, aggregating oracle data from each validator and writing the oracle data to the store.