supernode

package
v1.17.0 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2026 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Supernode

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

func New

func New(ctx context.Context, log gethlog.Logger, version string, requestStop context.CancelCauseFunc, cfg *config.CLIConfig, vnCfgs map[eth.ChainID]*opnodecfg.Config) (*Supernode, error)

func (*Supernode) BeaconClient

func (s *Supernode) BeaconClient() *sources.L1BeaconClient

BeaconClient returns the L1 Beacon client instance (may be nil if not configured)

func (*Supernode) InteropActivity

func (s *Supernode) InteropActivity() *interop.Interop

InteropActivity returns the single interop activity registered with the supernode, or nil if interop is not configured or has not started yet. Callers must not cache the returned pointer across RestartInteropActivity; that path swaps the underlying activity for a fresh instance.

func (*Supernode) L1Client

func (s *Supernode) L1Client() *sources.L1Client

L1Client returns the L1 client instance

func (*Supernode) RPCAddr

func (s *Supernode) RPCAddr() (addr string, ok bool)

RPCAddr returns the bound RPC address (host:port) if the server is listening. ok is false if the listener has not been created yet.

func (*Supernode) RestartInteropActivity

func (s *Supernode) RestartInteropActivity(wipeLogsDBs bool) error

RestartInteropActivity stops the running interop activity (if any), optionally wipes its on-disk logs DB files, constructs a fresh instance from the originally-configured parameters, re-registers it with each chain container as a verifier, and starts it under the supernode's existing lifecycle context. The HTTP server, chain containers, and all other activities keep running. This is the core primitive for tests that want to exercise log backfill against a running, ready cluster without the cost and flakiness of restarting the entire supernode.

Any test-only mutations on the old activity are discarded when it is Stopped.

func (*Supernode) Start

func (s *Supernode) Start(ctx context.Context) error

func (*Supernode) Stop

func (s *Supernode) Stop(ctx context.Context) error

func (*Supernode) Stopped

func (s *Supernode) Stopped() bool

func (*Supernode) WaitRPCAddr

func (s *Supernode) WaitRPCAddr(ctx context.Context) (string, error)

WaitRPCAddr blocks until the RPC server has a bound address or the context is done.

Jump to

Keyboard shortcuts

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