Documentation ¶
Overview ¶
Package roothash implements the roothash application.
Index ¶
- Constants
- Variables
- func New() tmapi.Application
- func QueryForRuntime(runtimeID common.Namespace) tmpubsub.Query
- func ValueRuntimeID(runtimeID common.Namespace) []byte
- type Query
- type QueryFactory
- type ValueExecutionDiscrepancyDetected
- type ValueExecutorCommitted
- type ValueFinalized
- type ValueMessage
Constants ¶
View Source
const ( // AppID is the unique application identifier. AppID uint8 = 0x02 // AppName is the ABCI application name. AppName string = "999_roothash" )
Variables ¶
View Source
var ( // EventType is the ABCI event type for roothash events. EventType = api.EventTypeForApp(AppName) // QueryApp is a query for filtering transactions processed by the // roothash application. QueryApp = api.QueryForApp(AppName) // KeyRuntimeID is an ABCI event attribute key for specifying event // runtime (value is Base64-encoded runtime ID). KeyRuntimeID = []byte("runtime-id") // KeyExecutorCommitted is an ABCI event attribute key for executor // commit events (value is CBOR-serialized ValueExecutorCommitted). KeyExecutorCommitted = []byte("executor-commit") // KeyMergeCommitted is an ABCI event attribute key for merge // commit events (value is CBOR-serialized ValueMergeCommitted). KeyMergeCommitted = []byte("merge-commit") // KeyMergeDiscrepancyDetected is an ABCI event attribute key for // merge discrepancy detected events (value is a CBOR serialized // ValueMergeDiscrepancyDetected). KeyMergeDiscrepancyDetected = []byte("merge-discrepancy") // KeyExecutionDiscrepancyDetected is an ABCI event attribute key for // merge discrepancy detected events (value is a CBOR serialized // ValueExecutionDiscrepancyDetected). KeyExecutionDiscrepancyDetected = []byte("execution-discrepancy") // KeyFinalized is an ABCI event attribute key for finalized blocks // (value is a CBOR serialized ValueFinalized). KeyFinalized = []byte("finalized") // KeyMessage is an ABCI event attribute key for message result events // (value is a CBOR serialized ValueMessage). KeyMessage = []byte("message") )
Functions ¶
func QueryForRuntime ¶
QueryForRuntime returns a query for filtering transactions processed by the roothash application limited to a specific runtime.
func ValueRuntimeID ¶
ValueRuntimeID returns the value that should be stored under KeyRuntimeID.
Types ¶
type Query ¶
type Query interface { LatestBlock(context.Context, common.Namespace) (*block.Block, error) GenesisBlock(context.Context, common.Namespace) (*block.Block, error) RuntimeState(context.Context, common.Namespace) (*roothash.RuntimeState, error) Genesis(context.Context) (*roothash.Genesis, error) }
Query is the roothash query interface.
type QueryFactory ¶
type QueryFactory struct {
// contains filtered or unexported fields
}
QueryFactory is the roothash query factory.
func NewQueryFactory ¶
func NewQueryFactory(state abciAPI.ApplicationQueryState) *QueryFactory
NewQueryFactory returns a new QueryFactory backed by the given state instance.
type ValueExecutionDiscrepancyDetected ¶
type ValueExecutionDiscrepancyDetected struct { ID common.Namespace `json:"id"` Event roothash.ExecutionDiscrepancyDetectedEvent `json:"event"` }
ValueExecutionDiscrepancyDetected is the value component of a KeyMergeDiscrepancyDetected.
type ValueExecutorCommitted ¶
type ValueExecutorCommitted struct { ID common.Namespace `json:"id"` Event roothash.ExecutorCommittedEvent `json:"event"` }
ValueExecutorCommitted is the value component of a KeyExecutorCommitted.
type ValueFinalized ¶
type ValueFinalized struct { ID common.Namespace `json:"id"` Event roothash.FinalizedEvent `json:"event"` }
ValueFinalized is the value component of a TagFinalized.
type ValueMessage ¶ added in v0.2100.0
type ValueMessage struct { ID common.Namespace `json:"id"` Event roothash.MessageEvent `json:"event"` }
ValueMessage is the value component of a KeyMessage.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.