Documentation
¶
Index ¶
- Constants
- Variables
- type Filter
- type FilterEvent
- type FilterTransactionMessage
- type HTTPClient
- type ProcessorService
- func (m *ProcessorService) ProcessBlock(ctx context.Context, block *coretypes.ResultBlock) error
- func (m *ProcessorService) ProcessBlockResults(ctx context.Context, blockResults *coretypes.ResultBlockResults, ...) error
- func (m *ProcessorService) ProcessEvent(ctx context.Context, event *abci.Event, header *types.Header) error
- func (m *ProcessorService) ProcessTransaction(ctx context.Context, tx []byte, txIndex int, header *types.Header) error
- type QueryProcessorService
- func (q *QueryProcessorService) GetMaxTopicID(ctx context.Context) (uint64, error)
- func (q *QueryProcessorService) ProcessEmissionInfo(ctx context.Context) error
- func (q *QueryProcessorService) ProcessGroundTruthData(ctx context.Context, topicID uint64) error
- func (q *QueryProcessorService) ProcessInflation(ctx context.Context) error
- func (q *QueryProcessorService) ProcessLatestAvailableNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) error
- func (q *QueryProcessorService) ProcessLatestNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) error
- func (q *QueryProcessorService) ProcessNaiveInfererNetworkRegret(ctx context.Context, topicID uint64) error
- func (q *QueryProcessorService) ProcessNetworkInferences(ctx context.Context, topicID uint64) error
- func (q *QueryProcessorService) ProcessReputerStakes(ctx context.Context, topicID uint64) error
- type QueryService
- func (q *QueryService) GetActiveReputers(ctx context.Context, topicID uint64) (emissionTypes.GetActiveReputersForTopicResponse, int64, error)
- func (q *QueryService) GetEmissionInfo(ctx context.Context) (*domain.QueryResult, error)
- func (q *QueryService) GetInflation(ctx context.Context) (*domain.QueryResult, error)
- func (q *QueryService) GetLatestAvailableNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
- func (q *QueryService) GetLatestNetworkInferences(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
- func (q *QueryService) GetLatestNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
- func (q *QueryService) GetNaiveInfererNetworkRegret(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
- func (q *QueryService) GetNextTopicID(ctx context.Context) (uint64, error)
- func (q *QueryService) GetOHLCData(ctx context.Context, ticker string, fromDate string) (domain.OHLCResponse, error)
- func (q *QueryService) GetReputerStake(ctx context.Context, reputerAddr string, topicID uint64) (math.Int, error)
- func (q *QueryService) Query(ctx context.Context, path string, in proto.Message, out proto.Message) (int64, error)
- func (q *QueryService) QueryJSON(ctx context.Context, path string, in proto.Message, out proto.Message) (*domain.QueryResult, error)
Constants ¶
View Source
const ( EmissionsServicePrefix = "/emissions.v7.QueryService/" MintServicePrefix = "/mint.v5.QueryService/" )
Variables ¶
View Source
var (
ErrParseTransaction = errors.New("failed to parse transaction")
)
Functions ¶
This section is empty.
Types ¶
type Filter ¶
type Filter struct {
// contains filtered or unexported fields
}
func (*Filter) ShouldProcess ¶
type FilterEvent ¶
type FilterEvent struct {
Filter
}
FilterEvent filters events based on the allowed types.
func NewFilterEvent ¶
func NewFilterEvent(allowedTypes ...string) *FilterEvent
NewFilterEvent creates a new FilterEvent.
func (*FilterEvent) ShouldProcess ¶
func (f *FilterEvent) ShouldProcess(event *abci.Event) bool
type FilterTransactionMessage ¶
type FilterTransactionMessage struct {
Filter
}
FilterTransactionMessage filters transaction messages based on the allowed types.
func NewFilterTransactionMessage ¶
func NewFilterTransactionMessage(allowedTypes ...string) *FilterTransactionMessage
NewFilterTransactionMessage creates a new FilterTransactionMessage.
func (*FilterTransactionMessage) ShouldProcess ¶
func (f *FilterTransactionMessage) ShouldProcess(txMsg *codectypes.Any) bool
type HTTPClient ¶ added in v0.1.22
type ProcessorService ¶
type ProcessorService struct {
// contains filtered or unexported fields
}
func NewProcessorService ¶
func NewProcessorService(streamingClient domain.StreamingClient, codec domain.CodecInterface, filterEvent domain.FilterInterface[abci.Event], filterTransactionMessage domain.FilterInterface[codectypes.Any]) (*ProcessorService, error)
func (*ProcessorService) ProcessBlock ¶
func (m *ProcessorService) ProcessBlock(ctx context.Context, block *coretypes.ResultBlock) error
ProcessBlock implements domain.ProcessorService.
func (*ProcessorService) ProcessBlockResults ¶
func (m *ProcessorService) ProcessBlockResults(ctx context.Context, blockResults *coretypes.ResultBlockResults, header *types.Header) error
ProcessBlockResults implements domain.ProcessorService.
func (*ProcessorService) ProcessEvent ¶
func (*ProcessorService) ProcessTransaction ¶
type QueryProcessorService ¶ added in v0.1.10
type QueryProcessorService struct {
// contains filtered or unexported fields
}
func NewQueryProcessor ¶ added in v0.1.10
func NewQueryProcessor(queryService domain.QueryService, repo domain.QueryResultRepositoryInterface, topicMetrics []config.TopicMetricConfig) (*QueryProcessorService, error)
func (*QueryProcessorService) GetMaxTopicID ¶ added in v0.1.10
func (q *QueryProcessorService) GetMaxTopicID(ctx context.Context) (uint64, error)
func (*QueryProcessorService) ProcessEmissionInfo ¶ added in v0.1.10
func (q *QueryProcessorService) ProcessEmissionInfo(ctx context.Context) error
func (*QueryProcessorService) ProcessGroundTruthData ¶ added in v0.1.14
func (q *QueryProcessorService) ProcessGroundTruthData(ctx context.Context, topicID uint64) error
func (*QueryProcessorService) ProcessInflation ¶ added in v0.1.10
func (q *QueryProcessorService) ProcessInflation(ctx context.Context) error
func (*QueryProcessorService) ProcessLatestAvailableNetworkInferencesOutlierResistant ¶ added in v0.1.20
func (q *QueryProcessorService) ProcessLatestAvailableNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) error
func (*QueryProcessorService) ProcessLatestNetworkInferencesOutlierResistant ¶ added in v0.1.20
func (q *QueryProcessorService) ProcessLatestNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) error
func (*QueryProcessorService) ProcessNaiveInfererNetworkRegret ¶ added in v0.1.10
func (q *QueryProcessorService) ProcessNaiveInfererNetworkRegret(ctx context.Context, topicID uint64) error
func (*QueryProcessorService) ProcessNetworkInferences ¶ added in v0.1.10
func (q *QueryProcessorService) ProcessNetworkInferences(ctx context.Context, topicID uint64) error
func (*QueryProcessorService) ProcessReputerStakes ¶ added in v0.1.15
func (q *QueryProcessorService) ProcessReputerStakes(ctx context.Context, topicID uint64) error
type QueryService ¶ added in v0.1.10
type QueryService struct {
// contains filtered or unexported fields
}
func NewQueryService ¶ added in v0.1.10
func NewQueryService(alloraClient domain.AlloraClientInterface, codec domain.CodecInterface, alloraAPIURL string, alloraAPIKey string) (*QueryService, error)
func (*QueryService) GetActiveReputers ¶ added in v0.1.15
func (q *QueryService) GetActiveReputers(ctx context.Context, topicID uint64) (emissionTypes.GetActiveReputersForTopicResponse, int64, error)
func (*QueryService) GetEmissionInfo ¶ added in v0.1.10
func (q *QueryService) GetEmissionInfo(ctx context.Context) (*domain.QueryResult, error)
func (*QueryService) GetInflation ¶ added in v0.1.10
func (q *QueryService) GetInflation(ctx context.Context) (*domain.QueryResult, error)
func (*QueryService) GetLatestAvailableNetworkInferencesOutlierResistant ¶ added in v0.1.20
func (q *QueryService) GetLatestAvailableNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
func (*QueryService) GetLatestNetworkInferences ¶ added in v0.1.10
func (q *QueryService) GetLatestNetworkInferences(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
func (*QueryService) GetLatestNetworkInferencesOutlierResistant ¶ added in v0.1.20
func (q *QueryService) GetLatestNetworkInferencesOutlierResistant(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
func (*QueryService) GetNaiveInfererNetworkRegret ¶ added in v0.1.10
func (q *QueryService) GetNaiveInfererNetworkRegret(ctx context.Context, topicID uint64) (*domain.QueryResult, error)
func (*QueryService) GetNextTopicID ¶ added in v0.1.10
func (q *QueryService) GetNextTopicID(ctx context.Context) (uint64, error)
func (*QueryService) GetOHLCData ¶ added in v0.1.14
func (q *QueryService) GetOHLCData(ctx context.Context, ticker string, fromDate string) (domain.OHLCResponse, error)
func (*QueryService) GetReputerStake ¶ added in v0.1.15
Click to show internal directories.
Click to hide internal directories.