Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = errors.New("not found")
Functions ¶
func SetPriceFeeder ¶
func SetPriceFeeder(pf *coingecko.PriceFeed) func(PeggyRelayer)
Types ¶
type BridgeValidators ¶
type BridgeValidators []*types.BridgeValidator
func (BridgeValidators) GetPowers ¶
func (b BridgeValidators) GetPowers() []uint64
GetPowers returns only the power values for all members
func (BridgeValidators) HasDuplicates ¶
func (b BridgeValidators) HasDuplicates() bool
HasDuplicates returns true if there are duplicates in the set
type PeggyRelayer ¶
type PeggyRelayer interface { Start(ctx context.Context) error FindLatestValset(ctx context.Context) (*peggytypes.Valset, error) RelayBatches( ctx context.Context, currentValset *peggytypes.Valset, possibleBatches map[common.Address][]SubmittableBatch, ) error RelayValsets(ctx context.Context, currentValset *peggytypes.Valset) error // SetPriceFeeder sets the (optional) price feeder used when performing profitable // batch calculations. SetPriceFeeder(*coingecko.PriceFeed) }
func NewPeggyRelayer ¶
func NewPeggyRelayer( logger zerolog.Logger, peggyQueryClient peggytypes.QueryClient, peggyContract peggy.Contract, valsetRelayEnabled bool, batchRelayEnabled bool, loopDuration time.Duration, pendingTxWait time.Duration, profitMultiplier float64, options ...func(PeggyRelayer), ) PeggyRelayer
type PeggyValsetUpdatedEvents ¶
type PeggyValsetUpdatedEvents []*wrappers.PeggyValsetUpdatedEvent
func (PeggyValsetUpdatedEvents) Len ¶
func (a PeggyValsetUpdatedEvents) Len() int
func (PeggyValsetUpdatedEvents) Less ¶
func (a PeggyValsetUpdatedEvents) Less(i, j int) bool
func (PeggyValsetUpdatedEvents) Swap ¶
func (a PeggyValsetUpdatedEvents) Swap(i, j int)
type SubmittableBatch ¶
type SubmittableBatch struct { Batch *types.OutgoingTxBatch Signatures []*types.MsgConfirmBatch }
Click to show internal directories.
Click to hide internal directories.