toml

package
v2.8.0-beta1 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2023 License: MIT Imports: 25 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// DefaultIDs is the set of chain ids which have defaults.
	DefaultIDs []*utils.Big
)

Functions

func ChainIDInt64 added in v2.6.0

func ChainIDInt64(cid relay.ChainID) (int64, error)

func ChainTypeForID

func ChainTypeForID(chainID *utils.Big) (config.ChainType, bool)

Types

type Automation

type Automation struct {
	GasLimit *uint32
}

type BalanceMonitor

type BalanceMonitor struct {
	Enabled *bool
}

type BlockHistoryEstimator

type BlockHistoryEstimator struct {
	BatchSize                 *uint32
	BlockHistorySize          *uint16
	CheckInclusionBlocks      *uint16
	CheckInclusionPercentile  *uint16
	EIP1559FeeCapBufferBlocks *uint16
	TransactionPercentile     *uint16
}

type Chain

type Chain struct {
	AutoCreateKey            *bool
	BlockBackfillDepth       *uint32
	BlockBackfillSkip        *bool
	ChainType                *string
	FinalityDepth            *uint32
	FinalityTagEnabled       *bool
	FlagsContractAddress     *ethkey.EIP55Address
	LinkContractAddress      *ethkey.EIP55Address
	LogBackfillBatchSize     *uint32
	LogPollInterval          *models.Duration
	LogKeepBlocksDepth       *uint32
	MinIncomingConfirmations *uint32
	MinContractPayment       *commonassets.Link
	NonceAutoSync            *bool
	NoNewHeadsThreshold      *models.Duration
	OperatorFactoryAddress   *ethkey.EIP55Address
	RPCDefaultBatchSize      *uint32
	RPCBlockQueryDelay       *uint16

	Transactions   Transactions      `toml:",omitempty"`
	BalanceMonitor BalanceMonitor    `toml:",omitempty"`
	GasEstimator   GasEstimator      `toml:",omitempty"`
	HeadTracker    HeadTracker       `toml:",omitempty"`
	KeySpecific    KeySpecificConfig `toml:",omitempty"`
	NodePool       NodePool          `toml:",omitempty"`
	OCR            OCR               `toml:",omitempty"`
	OCR2           OCR2              `toml:",omitempty"`
}

func Defaults

func Defaults(chainID *utils.Big, with ...*Chain) Chain

Defaults returns a Chain based on the defaults for chainID and fields from with, applied in order so later Chains override earlier ones.

func DefaultsNamed

func DefaultsNamed(chainID *utils.Big) (c Chain, name string)

DefaultsNamed returns the default Chain values, optionally for the given chainID, as well as a name if the chainID is known.

func (*Chain) SetFrom

func (c *Chain) SetFrom(f *Chain)

SetFrom updates c with any non-nil values from f.

func (*Chain) ValidateConfig

func (c *Chain) ValidateConfig() (err error)

type EVMConfig

type EVMConfig struct {
	ChainID *utils.Big
	Enabled *bool
	Chain
	Nodes EVMNodes
}

func (*EVMConfig) IsEnabled

func (c *EVMConfig) IsEnabled() bool

func (*EVMConfig) SetFrom

func (c *EVMConfig) SetFrom(f *EVMConfig)

func (*EVMConfig) TOMLString

func (c *EVMConfig) TOMLString() (string, error)

func (*EVMConfig) ValidateConfig

func (c *EVMConfig) ValidateConfig() (err error)

type EVMConfigs

type EVMConfigs []*EVMConfig

func (EVMConfigs) Chains

func (cs EVMConfigs) Chains(ids ...relay.ChainID) (r []commontypes.ChainStatus, total int, err error)

func (EVMConfigs) Node

func (cs EVMConfigs) Node(name string) (types.Node, error)

func (EVMConfigs) NodeStatus

func (cs EVMConfigs) NodeStatus(name string) (commontypes.NodeStatus, error)

func (EVMConfigs) NodeStatuses

func (cs EVMConfigs) NodeStatuses(chainIDs ...relay.ChainID) (ns []commontypes.NodeStatus, err error)

func (EVMConfigs) Nodes

func (cs EVMConfigs) Nodes(chainID relay.ChainID) (ns []types.Node, err error)

func (*EVMConfigs) SetFrom

func (cs *EVMConfigs) SetFrom(fs *EVMConfigs) (err error)

func (EVMConfigs) ValidateConfig

func (cs EVMConfigs) ValidateConfig() (err error)

type EVMNodes

type EVMNodes []*Node

func (*EVMNodes) SetFrom

func (ns *EVMNodes) SetFrom(fs *EVMNodes)

type GasEstimator

type GasEstimator struct {
	Mode *string

	PriceDefault *assets.Wei
	PriceMax     *assets.Wei
	PriceMin     *assets.Wei

	LimitDefault    *uint32
	LimitMax        *uint32
	LimitMultiplier *decimal.Decimal
	LimitTransfer   *uint32
	LimitJobType    GasLimitJobType `toml:",omitempty"`

	BumpMin       *assets.Wei
	BumpPercent   *uint16
	BumpThreshold *uint32
	BumpTxDepth   *uint32

	EIP1559DynamicFees *bool

	FeeCapDefault *assets.Wei
	TipCapDefault *assets.Wei
	TipCapMin     *assets.Wei

	BlockHistory BlockHistoryEstimator `toml:",omitempty"`
}

func (*GasEstimator) ValidateConfig

func (e *GasEstimator) ValidateConfig() (err error)

type GasLimitJobType

type GasLimitJobType struct {
	OCR    *uint32 `toml:",inline"`
	OCR2   *uint32 `toml:",inline"`
	DR     *uint32 `toml:",inline"`
	VRF    *uint32 `toml:",inline"`
	FM     *uint32 `toml:",inline"`
	Keeper *uint32 `toml:",inline"`
}

type HasEVMConfigs

type HasEVMConfigs interface {
	EVMConfigs() EVMConfigs
}

type HeadTracker

type HeadTracker struct {
	HistoryDepth     *uint32
	MaxBufferSize    *uint32
	SamplingInterval *models.Duration
}

type KeySpecific

type KeySpecific struct {
	Key          *ethkey.EIP55Address
	GasEstimator KeySpecificGasEstimator `toml:",omitempty"`
}

type KeySpecificConfig

type KeySpecificConfig []KeySpecific

func (KeySpecificConfig) ValidateConfig

func (ks KeySpecificConfig) ValidateConfig() (err error)

type KeySpecificGasEstimator

type KeySpecificGasEstimator struct {
	PriceMax *assets.Wei
}

type Node

type Node struct {
	Name     *string
	WSURL    *models.URL
	HTTPURL  *models.URL
	SendOnly *bool
	Order    *int32
}

func (*Node) SetFrom

func (n *Node) SetFrom(f *Node)

func (*Node) ValidateConfig

func (n *Node) ValidateConfig() (err error)

type NodePool

type NodePool struct {
	PollFailureThreshold *uint32
	PollInterval         *models.Duration
	SelectionMode        *string
	SyncThreshold        *uint32
	LeaseDuration        *models.Duration
}

type OCR

type OCR struct {
	ContractConfirmations              *uint16
	ContractTransmitterTransmitTimeout *models.Duration
	DatabaseTimeout                    *models.Duration
	DeltaCOverride                     *models.Duration
	DeltaCJitterOverride               *models.Duration
	ObservationGracePeriod             *models.Duration
}

type OCR2

type OCR2 struct {
	Automation Automation `toml:",omitempty"`
}

type Transactions

type Transactions struct {
	ForwardersEnabled    *bool
	MaxInFlight          *uint32
	MaxQueued            *uint32
	ReaperInterval       *models.Duration
	ReaperThreshold      *models.Duration
	ResendAfterThreshold *models.Duration
}

Jump to

Keyboard shortcuts

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