Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseProducer ¶
type BaseProducer struct {
// contains filtered or unexported fields
}
func (*BaseProducer) InitStartHeight ¶
func (bm *BaseProducer) InitStartHeight(ctx context.Context) error
InitStartHeight checks if the start height is zero and fetches the latest block height.
func (*BaseProducer) MonitorLoop ¶
func (bm *BaseProducer) MonitorLoop(ctx context.Context, processBlock func(ctx context.Context, height int64) error) error
MonitorLoop allows each specific producer to define how it processes blocks or block results.
type EventsProducer ¶
type EventsProducer struct {
BaseProducer
}
func NewEventsProducer ¶
func NewEventsProducer(service domain.ProcessorService, client domain.AlloraClientInterface, repository domain.ProcessedBlockRepositoryInterface, startHeight int64, blockRefreshInterval time.Duration, rateLimitInterval time.Duration, numWorkers int) (*EventsProducer, error)
type TransactionsProducer ¶
type TransactionsProducer struct {
BaseProducer
}
func NewTransactionsProducer ¶
func NewTransactionsProducer(service domain.ProcessorService, client domain.AlloraClientInterface, repository domain.ProcessedBlockRepositoryInterface, startHeight int64, blockRefreshInterval time.Duration, rateLimitInterval time.Duration, numWorkers int) (*TransactionsProducer, error)
Click to show internal directories.
Click to hide internal directories.