Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoLogs = errors.New("no logs available for transforming") ErrNoTransformers = errors.New("no event transformers configured in the log delegator") )
View Source
var ( ErrNoUncheckedHeaders = errors.New("no unchecked headers available for log fetching") ErrNoWatchedAddresses = errors.New("no watched addresses configured in the log extractor") )
Functions ¶
This section is empty.
Types ¶
type ILogDelegator ¶
type ILogDelegator interface { AddTransformer(t transformer.EventTransformer) DelegateLogs() error }
type ILogExtractor ¶
type ILogExtractor interface { AddTransformerConfig(config transformer.EventTransformerConfig) error ExtractLogs(recheckHeaders constants.TransformerExecution) error }
type LogDelegator ¶
type LogDelegator struct { Chunker chunker.Chunker LogRepository datastore.EventLogRepository Transformers []transformer.EventTransformer }
func NewLogDelegator ¶ added in v0.1.0
func NewLogDelegator(db *postgres.DB) *LogDelegator
func (*LogDelegator) AddTransformer ¶
func (delegator *LogDelegator) AddTransformer(t transformer.EventTransformer)
func (*LogDelegator) DelegateLogs ¶
func (delegator *LogDelegator) DelegateLogs() error
type LogExtractor ¶
type LogExtractor struct { Addresses []common.Address CheckedHeadersRepository datastore.CheckedHeadersRepository CheckedLogsRepository datastore.CheckedLogsRepository Fetcher fetcher.ILogFetcher LogRepository datastore.EventLogRepository StartingBlock *int64 EndingBlock *int64 Syncer transactions.ITransactionsSyncer Topics []common.Hash RecheckHeaderCap int64 }
func NewLogExtractor ¶ added in v0.1.0
func NewLogExtractor(db *postgres.DB, bc core.BlockChain) *LogExtractor
func (*LogExtractor) AddTransformerConfig ¶
func (extractor *LogExtractor) AddTransformerConfig(config transformer.EventTransformerConfig) error
Add additional logs to extract
func (LogExtractor) ExtractLogs ¶
func (extractor LogExtractor) ExtractLogs(recheckHeaders constants.TransformerExecution) error
Fetch and persist watched logs
Click to show internal directories.
Click to hide internal directories.