transmission

package
v2.13.0-rc0 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// S = [N]
	Schedule_AllAtOnce = "allAtOnce"
	// S = [1 * N]
	Schedule_OneAtATime = "oneAtATime"
)

Functions

func GetPeerIDToTransmissionDelay

func GetPeerIDToTransmissionDelay(donPeerIDs []ragep2ptypes.PeerID, sharedSecret [16]byte, transmissionID string, tc TransmissionConfig) (map[p2ptypes.PeerID]time.Duration, error)

GetPeerIDToTransmissionDelay returns a map of PeerID to the time.Duration that the node with that PeerID should wait before transmitting. If a node is not in the map, it should not transmit. The sharedSecret is shared by nodes in the same DON and used to generate a deterministic schedule for the transmission delays.

Types

type LocalTargetCapability

type LocalTargetCapability struct {
	capabilities.TargetCapability
	// contains filtered or unexported fields
}

LocalTargetCapability handles the transmission protocol required for a target capability that exists in the same don as the caller.

func NewLocalTargetCapability

func NewLocalTargetCapability(lggr logger.Logger, peerID p2ptypes.PeerID, don capabilities.DON, underlying capabilities.TargetCapability) *LocalTargetCapability

func (*LocalTargetCapability) Execute

type TransmissionConfig

type TransmissionConfig struct {
	Schedule   string
	DeltaStage time.Duration
}

func ExtractTransmissionConfig

func ExtractTransmissionConfig(config *values.Map) (TransmissionConfig, error)

Jump to

Keyboard shortcuts

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