Documentation ¶
Index ¶
- func MonitorTick(ctx context.Context, cf context.CancelFunc, eth layer1.Client, ...) error
- func NewMonitor(cdb *db.Database, monDB *db.Database, adminHandler interfaces.AdminHandler, ...) (*monitor, error)
- func PersistSnapshot(eth layer1.Client, bh *objs.BlockHeader, numOfValidators int, ...) error
- func ProcessEvents(eth layer1.Client, contracts layer1.AllSmartContracts, ...) (uint64, error)
- type Monitor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MonitorTick ¶
func MonitorTick(ctx context.Context, cf context.CancelFunc, eth layer1.Client, allContracts layer1.AllSmartContracts, monitorState *objects.MonitorState, logger *logrus.Entry, eventMap *objects.EventMap, adminHandler interfaces.AdminHandler, batchSize uint64, filterContracts []common.Address, ) error
MonitorTick using existing monitorState and incrementally updates it based on current State of Ethereum endpoint.
func NewMonitor ¶
func NewMonitor(cdb *db.Database, monDB *db.Database, adminHandler interfaces.AdminHandler, depositHandler interfaces.DepositHandler, eth layer1.Client, contracts layer1.AllSmartContracts, eventFilterAddresses []common.Address, tickInterval time.Duration, batchSize uint64, chainId uint32, taskHandler executor.TaskHandler, ) (*monitor, error)
NewMonitor creates a new Monitor.
func PersistSnapshot ¶
func PersistSnapshot(eth layer1.Client, bh *objs.BlockHeader, numOfValidators int, validatorIndex int, taskHandler executor.TaskHandler, monDB *db.Database) error
PersistSnapshot should be registered as a callback and be kicked off automatically by badger when appropriate
Types ¶
Click to show internal directories.
Click to hide internal directories.