Documentation
¶
Index ¶
- type Config
- type Features
- func (f Features) EnabledFlags() []string
- func (f Features) GetFetchBeaconBadBlob() bool
- func (f Features) GetFetchBeaconBadBlock() bool
- func (f Features) GetFetchBeaconBlock() bool
- func (f Features) GetFetchBeaconState() bool
- func (f Features) GetFetchExecutionBadBlock() bool
- func (f Features) GetFetchExecutionBlockTrace() bool
- func (f Features) GetFetchExecutionPayloadEnvelope() bool
- func (f Features) Validate() error
- type Node
- func (n *Node) Beacon() *beacon.Node
- func (n *Node) Execution() *execution.Node
- func (n *Node) Failed() <-chan error
- func (n *Node) OnReady(_ context.Context, callback func(ctx context.Context) error)
- func (n *Node) ShouldIgnoreEventFromSlot(slot phase0.Slot) (bool, error)
- func (n *Node) Start(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// Execution configuration
Execution *execution.Config `yaml:"execution"`
// Beacon configuration
Beacon *beacon.Config `yaml:"beacon"`
// OverrideNetworkName is the name of the network to use for the agent.
// If not set, the network name will be retrieved from the beacon node.
OverrideNetworkName string `yaml:"overrideNetworkName" default:""`
// Features configuration
Features Features `yaml:"features"`
// SyncToleranceSlots is the age of the block in slots that is tolerated before it is not fetched.
// This is to prevent fetching blocks that are too far behind the head.
SyncToleranceSlots phase0.Slot `yaml:"syncToleranceSlots" default:"64"`
// BeaconStateAgeThresholdEpochs is the number of epochs that a beacon state is allowed to be old.
// This should be used to prevent fetching states that are too far behind the head,
// which can cause the agent to get stuck as old states might not be available in
// the beacon node cache.
BeaconStateAgeThresholdEpochs uint64 `yaml:"beaconStateAgeThresholdEpochs" default:"1"`
// ExecutionBlockTraceAgeThresholdBlocks is how far behind the execution head
// a block may be before its trace is no longer worth requesting. Execution
// clients retain only enough state to re-execute a bounded number of recent
// blocks, so a trace beyond that window is a guaranteed failure. The default
// follows geth's `reexec` default of 128 blocks.
ExecutionBlockTraceAgeThresholdBlocks uint64 `yaml:"executionBlockTraceAgeThresholdBlocks" default:"128"`
// MaxConcurrentExecutionBadBlockFetches bounds how many debug_getBadBlocks
// responses are being streamed at once across every agent in the process.
// Each in-flight stream holds one decoded bad block, so this is the knob
// that sizes the memory the bad block sweep may use. Applied process-wide
// by whichever agent starts first.
MaxConcurrentExecutionBadBlockFetches int `yaml:"maxConcurrentExecutionBadBlockFetches" default:"4"`
}
func (*Config) GetExecutionBlockTraceAgeThresholdBlocks ¶ added in v0.1.0
func (*Config) GetMaxConcurrentExecutionBadBlockFetches ¶ added in v0.1.0
type Features ¶ added in v0.0.19
type Features struct {
FetchBeaconState *bool `yaml:"fetchBeaconState" default:"true"`
FetchBeaconBlock *bool `yaml:"fetchBeaconBlock" default:"true"`
FetchExecutionPayloadEnvelope *bool `yaml:"fetchExecutionPayloadEnvelope" default:"true"`
FetchBeaconBadBlock *bool `yaml:"fetchBeaconBadBlock" default:"true"`
FetchBeaconBadBlob *bool `yaml:"fetchBeaconBadBlob" default:"true"`
FetchExecutionBlockTrace *bool `yaml:"fetchExecutionBlockTrace" default:"true"`
FetchExecutionBadBlock *bool `yaml:"fetchExecutionBadBlock" default:"true"`
}
Features contains feature flags for the agent.
func (Features) EnabledFlags ¶ added in v0.0.19
EnabledFlags returns a list of enabled feature flags.
func (Features) GetFetchBeaconBadBlob ¶ added in v0.0.19
func (Features) GetFetchBeaconBadBlock ¶ added in v0.0.19
func (Features) GetFetchBeaconBlock ¶ added in v0.0.19
func (Features) GetFetchBeaconState ¶ added in v0.0.19
func (Features) GetFetchExecutionBadBlock ¶ added in v0.0.19
func (Features) GetFetchExecutionBlockTrace ¶ added in v0.0.19
func (Features) GetFetchExecutionPayloadEnvelope ¶ added in v0.1.0
type Node ¶
type Node struct {
// contains filtered or unexported fields
}
func (*Node) Failed ¶ added in v0.1.0
Failed reports that this node can no longer be used. It is how one sick node stops one agent instead of the process it happens to share.
func (*Node) ShouldIgnoreEventFromSlot ¶ added in v0.0.28
Click to show internal directories.
Click to hide internal directories.