svc

package
v0.0.0-...-4c8f420 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2023 License: GPL-3.0 Imports: 24 Imported by: 0

Documentation

Overview

Package svc implements monitoring and scanning services of the API server.

Package svc implements monitoring and scanning services of the API server.

Index

Constants

View Source
const (
	TestChainId       = 1337
	TestChainGasLimit = 10000000000
	TestChainGasPrice = 6721975
)

Variables

This section is empty.

Functions

This section is empty.

Types

type EventHandler

type EventHandler func(context.Context, *eth.Log, *db.Db) error

EventHandler represents a function used to process event log record.

type Manager

type Manager struct {
	// contains filtered or unexported fields
}

Manager represents the manager controlling services lifetime.

func New

func New(cfg *config.Config, repo *repository.Repository, log *logger.AppLogger) *Manager

func (*Manager) Close

func (mgr *Manager) Close()

Close terminates the service manager and all the managed services along with it.

func (*Manager) Run

func (mgr *Manager) Run()

Run starts all the services prepared to be run.

type TestChain

type TestChain struct {
	RawRpc             *client.Client
	AdminAcc           *testAccount
	FunderAcc          *testAccount
	ProjectsManagerAcc *testAccount
	ProjectOwnerAcc    *testAccount
	DataProviderAcc    *testAccount
	// contains filtered or unexported fields
}

func SetupTestChain

func SetupTestChain(logger *logger.AppLogger) *TestChain

func (*TestChain) SetupTestRpc

func (tch *TestChain) SetupTestRpc(contractAddress common.Address, logger *logger.AppLogger) *rpc.Rpc

SetupTestRpc initializes rpc client

func (*TestChain) TearDown

func (tch *TestChain) TearDown()

Jump to

Keyboard shortcuts

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