Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlockOptions ¶
type BlockOptions = common.BlockOptions
BlockOptions defines the options for creating block components
func DefaultBlockOptions ¶
func DefaultBlockOptions() BlockOptions
DefaultBlockOptions returns the default block options
type Components ¶
type Components struct {
Executor *executing.Executor
Reaper *reaping.Reaper
Syncer *syncing.Syncer
Submitter *submitting.Submitter
Cache cache.Manager
// contains filtered or unexported fields
}
Components represents the block-related components
func NewAggregatorComponents ¶
func NewAggregatorComponents( config config.Config, genesis genesis.Genesis, store store.Store, exec coreexecutor.Executor, sequencer coresequencer.Sequencer, da coreda.DA, signer signer.Signer, headerBroadcaster broadcaster[*types.SignedHeader], dataBroadcaster broadcaster[*types.Data], logger zerolog.Logger, metrics *Metrics, blockOpts BlockOptions, ) (*Components, error)
NewAggregatorComponents creates components for an aggregator full node that can produce and sync blocks. Aggregator nodes have full capabilities - they can produce blocks, sync from P2P and DA, and submit headers/data to DA. Requires a signer for block production and DA submission.
func NewSyncComponents ¶
func NewSyncComponents( config config.Config, genesis genesis.Genesis, store store.Store, exec coreexecutor.Executor, da coreda.DA, headerStore goheader.Store[*types.SignedHeader], dataStore goheader.Store[*types.Data], logger zerolog.Logger, metrics *Metrics, blockOpts BlockOptions, ) (*Components, error)
NewSyncComponents creates components for a non-aggregator full node that can only sync blocks. Non-aggregator full nodes can sync from P2P and DA but cannot produce blocks or submit to DA. They have more sync capabilities than light nodes but no block production. No signer required.
func (*Components) GetLastState ¶
func (bc *Components) GetLastState() types.State
GetLastState returns the current blockchain state
type Metrics ¶
Expose Metrics for constructor
func PrometheusMetrics ¶
PrometheusMetrics creates a new PrometheusMetrics instance with the given namespace and labelsAndValues.