Documentation ¶
Index ¶
- func CreateDelayBroadcastDataForLeader(headerHash []byte, miniblocks map[uint32][]byte, ...) *delayedBroadcastData
- func CreateDelayBroadcastDataForValidator(headerHash []byte, header data.HeaderHandler, miniblocksData map[uint32][]byte, ...) *delayedBroadcastData
- func CreateValidatorHeaderBroadcastData(headerHash []byte, header data.HeaderHandler, ...) *validatorHeaderBroadcastData
- func NewCommonMessenger(marshalizer marshal.Marshalizer, messenger consensus.P2PMessenger, ...) (*commonMessenger, error)
- func NewDelayedBlockBroadcaster(args *ArgsDelayedBlockBroadcaster) (*delayedBlockBroadcaster, error)
- func NewMetaChainMessenger(args MetaChainMessengerArgs) (*metaChainMessenger, error)
- func NewShardChainMessenger(args ShardChainMessengerArgs) (*shardChainMessenger, error)
- func ValidatorDelayPerOrder() time.Duration
- type ArgsDelayedBlockBroadcaster
- type CommonMessengerArgs
- type HeaderDataForValidator
- type MetaChainMessengerArgs
- type ShardChainMessengerArgs
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateDelayBroadcastDataForLeader ¶ added in v1.0.133
func CreateDelayBroadcastDataForLeader( headerHash []byte, miniblocks map[uint32][]byte, transactions map[string][][]byte, ) *delayedBroadcastData
CreateDelayBroadcastDataForLeader -
func CreateDelayBroadcastDataForValidator ¶ added in v1.0.133
func CreateDelayBroadcastDataForValidator( headerHash []byte, header data.HeaderHandler, miniblocksData map[uint32][]byte, miniBlockHashes map[string]map[string]struct{}, transactionsData map[string][][]byte, order uint32, ) *delayedBroadcastData
CreateDelayBroadcastDataForValidator creates the delayed broadcast data
func CreateValidatorHeaderBroadcastData ¶ added in v1.0.133
func CreateValidatorHeaderBroadcastData( headerHash []byte, header data.HeaderHandler, metaMiniBlocksData map[uint32][]byte, metaTransactionsData map[string][][]byte, order uint32, ) *validatorHeaderBroadcastData
CreateValidatorHeaderBroadcastData creates a validatorHeaderBroadcastData object from the given parameters
func NewCommonMessenger ¶
func NewCommonMessenger( marshalizer marshal.Marshalizer, messenger consensus.P2PMessenger, privateKey crypto.PrivateKey, shardCoordinator sharding.Coordinator, peerSigHandler crypto.PeerSignatureHandler, ) (*commonMessenger, error)
NewCommonMessenger will return a new instance of a commonMessenger
func NewDelayedBlockBroadcaster ¶ added in v1.0.133
func NewDelayedBlockBroadcaster(args *ArgsDelayedBlockBroadcaster) (*delayedBlockBroadcaster, error)
NewDelayedBlockBroadcaster create a new instance of a delayed block data broadcaster
func NewMetaChainMessenger ¶
func NewMetaChainMessenger( args MetaChainMessengerArgs, ) (*metaChainMessenger, error)
NewMetaChainMessenger creates a new metaChainMessenger object
func NewShardChainMessenger ¶
func NewShardChainMessenger( args ShardChainMessengerArgs, ) (*shardChainMessenger, error)
NewShardChainMessenger creates a new shardChainMessenger object
func ValidatorDelayPerOrder ¶ added in v1.0.133
ValidatorDelayPerOrder -
Types ¶
type ArgsDelayedBlockBroadcaster ¶ added in v1.0.133
type ArgsDelayedBlockBroadcaster struct { InterceptorsContainer process.InterceptorsContainer HeadersSubscriber consensus.HeadersPoolSubscriber ShardCoordinator sharding.Coordinator LeaderCacheSize uint32 ValidatorCacheSize uint32 AlarmScheduler timersScheduler }
ArgsDelayedBlockBroadcaster holds the arguments to create a delayed block broadcaster
type CommonMessengerArgs ¶ added in v1.0.106
type CommonMessengerArgs struct { Marshalizer marshal.Marshalizer Hasher hashing.Hasher Messenger consensus.P2PMessenger PrivateKey crypto.PrivateKey ShardCoordinator sharding.Coordinator PeerSignatureHandler crypto.PeerSignatureHandler HeadersSubscriber consensus.HeadersPoolSubscriber InterceptorsContainer process.InterceptorsContainer MaxDelayCacheSize uint32 MaxValidatorDelayCacheSize uint32 AlarmScheduler core.TimersScheduler }
CommonMessengerArgs holds the arguments for creating commonMessenger instance
type HeaderDataForValidator ¶ added in v1.0.133
HeaderDataForValidator -
func GetShardDataFromMetaChainBlock ¶ added in v1.0.133
func GetShardDataFromMetaChainBlock( headerHandler data.HeaderHandler, shardID uint32, ) ([][]byte, []*HeaderDataForValidator, error)
GetShardDataFromMetaChainBlock -
type MetaChainMessengerArgs ¶ added in v1.0.106
type MetaChainMessengerArgs struct {
CommonMessengerArgs
}
MetaChainMessengerArgs holds the arguments for creating a metaChainMessenger instance
type ShardChainMessengerArgs ¶ added in v1.0.106
type ShardChainMessengerArgs struct {
CommonMessengerArgs
}
ShardChainMessengerArgs holds the arguments for creating a shardChainMessenger instance