processor

package
v0.0.0-...-e8e2c10 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2024 License: Apache-2.0 Imports: 19 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CalculateQuorum

func CalculateQuorum(numGuardians int) int

CalculateQuorum returns the minimum number of guardians that need to sign a VAA for a given guardian set.

The canonical source is the calculation in the contracts (solana/bridge/src/processor.rs and ethereum/contracts/Wormhole.sol), and this needs to match the implementation in the contracts.

Types

type Processor

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

func NewProcessor

func NewProcessor(
	ctx context.Context,
	db *db.Database,
	lockC chan *common.MessagePublication,
	setC chan *common.GuardianSet,
	sendC chan []byte,
	obsvC chan *gossipv1.SignedObservation,
	obsvReqSendC chan<- *gossipv1.ObservationRequest,
	injectC chan *vaa.VAA,
	signedInC chan *gossipv1.SignedVAAWithQuorum,
	guardianSigner ecdsasigner.ECDSASigner,
	gst *common.GuardianSetState,
	attestationEvents *reporter.AttestationEventReporter,
	notifier *discord.DiscordNotifier,
	governanceChainId vaa.ChainID,
	governanceEmitterAddress vaa.Address,
) *Processor

func (*Processor) Run

func (p *Processor) Run(ctx context.Context) error

Jump to

Keyboard shortcuts

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