factory

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2023 License: GPL-3.0 Imports: 45 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAccountsDBSContainerFactory

func NewAccountsDBSContainerFactory(args ArgsNewAccountsDBSyncersContainerFactory) (*accountDBSyncersContainerFactory, error)

NewAccountsDBSContainerFactory creates a factory for trie syncers container

func NewDataTrieFactory

func NewDataTrieFactory(args ArgsNewDataTrieFactory) (*dataTrieFactory, error)

NewDataTrieFactory creates a data trie factory

func NewExportHandlerFactory

func NewExportHandlerFactory(args ArgsExporter) (*exportHandlerFactory, error)

NewExportHandlerFactory creates an exporter factory

func NewFullSyncInterceptorsContainerFactory

func NewFullSyncInterceptorsContainerFactory(
	args ArgsNewFullSyncInterceptorsContainerFactory,
) (*fullSyncInterceptorsContainerFactory, error)

NewFullSyncInterceptorsContainerFactory is responsible for creating a new interceptors factory object

func NewResolversContainerFactory

func NewResolversContainerFactory(args ArgsNewResolversContainerFactory) (*resolversContainerFactory, error)

NewResolversContainerFactory creates a new container filled with topic resolvers

func NewTrieSyncersContainerFactory

func NewTrieSyncersContainerFactory(args ArgsNewTrieSyncersContainerFactory) (*trieSyncersContainerFactory, error)

NewTrieSyncersContainerFactory creates a factory for trie syncers container

Types

type ArgsExporter

type ArgsExporter struct {
	TxSignMarshalizer        marshal.Marshalizer
	Marshalizer              marshal.Marshalizer
	Hasher                   hashing.Hasher
	HeaderValidator          epochStart.HeaderValidator
	Uint64Converter          typeConverters.Uint64ByteSliceConverter
	DataPool                 dataRetriever.PoolsHolder
	StorageService           dataRetriever.StorageService
	RequestHandler           process.RequestHandler
	ShardCoordinator         sharding.Coordinator
	Messenger                p2p.Messenger
	ActiveAccountsDBs        map[state.AccountsDbIdentifier]state.AccountsAdapter
	ExistingResolvers        dataRetriever.ResolversContainer
	ExportFolder             string
	ExportTriesStorageConfig config.StorageConfig
	ExportStateStorageConfig config.StorageConfig
	ExportStateKeysConfig    config.StorageConfig
	MaxTrieLevelInMemory     uint
	WhiteListHandler         process.WhiteListHandler
	WhiteListerVerifiedTxs   process.WhiteListHandler
	InterceptorsContainer    process.InterceptorsContainer
	MultiSigner              crypto.MultiSigner
	NodesCoordinator         sharding.NodesCoordinator
	SingleSigner             crypto.SingleSigner
	AddressPubKeyConverter   core.PubkeyConverter
	ValidatorPubKeyConverter core.PubkeyConverter
	BlockKeyGen              crypto.KeyGenerator
	KeyGen                   crypto.KeyGenerator
	BlockSigner              crypto.SingleSigner
	HeaderSigVerifier        process.InterceptedHeaderSigVerifier
	HeaderIntegrityVerifier  process.InterceptedHeaderIntegrityVerifier
	ValidityAttester         process.ValidityAttester
	InputAntifloodHandler    process.P2PAntifloodHandler
	OutputAntifloodHandler   process.P2PAntifloodHandler
	ChainID                  []byte
	Rounder                  process.Rounder
	GenesisNodesSetupHandler update.GenesisNodesSetupHandler
}

ArgsExporter is the argument structure to create a new exporter

type ArgsNewAccountsDBSyncersContainerFactory

type ArgsNewAccountsDBSyncersContainerFactory struct {
	TrieCacher           storage.Cacher
	RequestHandler       update.RequestHandler
	ShardCoordinator     sharding.Coordinator
	Hasher               hashing.Hasher
	Marshalizer          marshal.Marshalizer
	TrieStorageManager   data.StorageManager
	WaitTime             time.Duration
	MaxTrieLevelInMemory uint
}

ArgsNewAccountsDBSyncersContainerFactory defines the arguments needed to create accounts DB syncers container

type ArgsNewDataTrieFactory

type ArgsNewDataTrieFactory struct {
	StorageConfig        config.StorageConfig
	SyncFolder           string
	Marshalizer          marshal.Marshalizer
	Hasher               hashing.Hasher
	ShardCoordinator     sharding.Coordinator
	MaxTrieLevelInMemory uint
}

ArgsNewDataTrieFactory is the argument structure for the new data trie factory

type ArgsNewFullSyncInterceptorsContainerFactory

type ArgsNewFullSyncInterceptorsContainerFactory struct {
	Accounts                state.AccountsAdapter
	ShardCoordinator        sharding.Coordinator
	NodesCoordinator        sharding.NodesCoordinator
	Messenger               process.TopicHandler
	Store                   dataRetriever.StorageService
	Marshalizer             marshal.Marshalizer
	TxSignMarshalizer       marshal.Marshalizer
	Hasher                  hashing.Hasher
	KeyGen                  crypto.KeyGenerator
	BlockSignKeyGen         crypto.KeyGenerator
	SingleSigner            crypto.SingleSigner
	BlockSingleSigner       crypto.SingleSigner
	MultiSigner             crypto.MultiSigner
	DataPool                dataRetriever.PoolsHolder
	AddressPubkeyConverter  core.PubkeyConverter
	MaxTxNonceDeltaAllowed  int
	TxFeeHandler            process.FeeHandler
	BlockBlackList          process.TimeCacher
	HeaderSigVerifier       process.InterceptedHeaderSigVerifier
	HeaderIntegrityVerifier process.InterceptedHeaderIntegrityVerifier
	SizeCheckDelta          uint32
	ValidityAttester        process.ValidityAttester
	EpochStartTrigger       process.EpochStartTriggerHandler
	WhiteListHandler        update.WhiteListHandler
	WhiteListerVerifiedTxs  update.WhiteListHandler
	InterceptorsContainer   process.InterceptorsContainer
	AntifloodHandler        process.P2PAntifloodHandler
	NonceConverter          typeConverters.Uint64ByteSliceConverter
	ChainID                 []byte
}

ArgsNewFullSyncInterceptorsContainerFactory holds the arguments needed for fullSyncInterceptorsContainerFactory

type ArgsNewResolversContainerFactory

type ArgsNewResolversContainerFactory struct {
	ShardCoordinator           sharding.Coordinator
	Messenger                  dataRetriever.TopicMessageHandler
	Marshalizer                marshal.Marshalizer
	DataTrieContainer          state.TriesHolder
	ExistingResolvers          dataRetriever.ResolversContainer
	InputAntifloodHandler      dataRetriever.P2PAntifloodHandler
	OutputAntifloodHandler     dataRetriever.P2PAntifloodHandler
	NumConcurrentResolvingJobs int32
}

ArgsNewResolversContainerFactory defines the arguments for the resolversContainerFactory constructor

type ArgsNewTrieSyncersContainerFactory

type ArgsNewTrieSyncersContainerFactory struct {
	TrieCacher        storage.Cacher
	SyncFolder        string
	RequestHandler    update.RequestHandler
	DataTrieContainer state.TriesHolder
	ShardCoordinator  sharding.Coordinator
}

ArgsNewTrieSyncersContainerFactory defines the arguments needed to create trie syncers container

Jump to

Keyboard shortcuts

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