gossip

package
v0.2.4-0...-f8342f3 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AttesterSlashing string = "/eth2/b5303f2a/attester_slashing/ssz_snappy"
View Source
var BeaconAggregateProof string = "/eth2/b5303f2a/beacon_aggregate_and_proof/ssz_snappy"
View Source
var BeaconBlock string = "/eth2/b5303f2a/beacon_block/ssz_snappy"
View Source
var MainnetForkDigest string = "b5303f2a"
View Source
var ProposerSlashing string = "/eth2/b5303f2a/proposer_slashing/ssz_snappy"
View Source
var VoluntaryExit string = "/eth2/b5303f2a/voluntary_exit/ssz_snappy"

Functions

func GenerateEth2Topics

func GenerateEth2Topics(forkDigest string, topic string, encoding string) string

func MsgIDFunction

func MsgIDFunction(pmsg *pubsub_pb.Message) string

Types

type AcceptStatus

type AcceptStatus int

type GossipSub

type GossipSub interface {
	Join(topic string, opts ...pubsub.TopicOpt) (*pubsub.Topic, error)
	BlacklistPeer(id peer.ID)
}

func NewGossipSub

func NewGossipSub(ctx context.Context, h host.Host, seenFilter bool) (GossipSub, error)

type ReceivedAttestation

type ReceivedAttestation struct {
	ReceivedTime      time.Time
	From              peer.ID
	BeaconAttestation beacon.Attestation
}

Attestation Message Metadata Struct

type ReceivedAttesterSlashing

type ReceivedAttesterSlashing struct {
	ReceivedTime     time.Time
	From             peer.ID
	AttesterSlashing beacon.AttesterSlashing
}

Attester Slashing Message Metadata Struct

type ReceivedProposerSlashing

type ReceivedProposerSlashing struct {
	ReceivedTime     time.Time
	From             peer.ID
	ProposerSlashing beacon.ProposerSlashing
}

Proposer Slashing Message Metadata Struct

type ReceivedVoluntaryExit

type ReceivedVoluntaryExit struct {
	ReceivedTime  time.Time
	From          peer.ID
	VoluntaryExit beacon.VoluntaryExit
}

Voluntary Exit Message Metadata Struct

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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