fetcher

package
v0.1.27 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 13, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package fetcher gets data from scribe.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ScribeFetcher

type ScribeFetcher interface {
	// FetchLastIndexed fetches the last indexed block per contract.
	FetchLastIndexed(ctx context.Context, chainID uint32, contractAddress string) (uint64, error)
	// FetchLogsAndTransactionsRange fetches logs and transactions in a range with the GQL client.
	FetchLogsAndTransactionsRange(ctx context.Context, chainID uint32, startBlock, endBlock uint64, contractAddress common.Address, page int) ([]ethTypes.Log, []types.TxSupplementalInfo, error)
}

ScribeFetcher is the interface for fetching events. It uses GQL.

func NewFetcher

func NewFetcher(fetchClient *client.Client, handler metrics.Handler) ScribeFetcher

NewFetcher creates a new fetcher.

Directories

Path Synopsis
Package client provides a GraphQL client for consuming logs.
Package client provides a GraphQL client for consuming logs.
contrib
Package main generates a GQL client.
Package main generates a GQL client.
model
Package model defines models returned by the graphql server
Package model defines models returned by the graphql server
resolver
Package resolvers resolves data from gqlgen
Package resolvers resolves data from gqlgen
types
Package types provides the GraphQL types for the Scribe service.
Package types provides the GraphQL types for the Scribe service.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL