status

package
v1.16.4 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2025 License: MIT, MIT Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type L1Tracker added in v1.9.0

type L1Tracker struct {
	derive.L1Fetcher
	// contains filtered or unexported fields
}

L1Tracker implements the L1Fetcher interface while proactively maintaining a reorg-aware cache of L1 block references by number. Populate the cache with the latest L1 block references.

func NewL1Tracker added in v1.9.0

func NewL1Tracker(inner derive.L1Fetcher) *L1Tracker

func (*L1Tracker) L1BlockRefByNumber added in v1.9.0

func (l *L1Tracker) L1BlockRefByNumber(ctx context.Context, num uint64) (eth.L1BlockRef, error)

func (*L1Tracker) OnL1Unsafe added in v1.13.6

func (st *L1Tracker) OnL1Unsafe(l1Unsafe eth.BlockRef)

type Metrics

type Metrics interface {
	RecordL1ReorgDepth(d uint64)
	RecordL1Ref(name string, ref eth.L1BlockRef)
}

type StatusTracker

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

func NewStatusTracker

func NewStatusTracker(log log.Logger, metrics Metrics) *StatusTracker

func (*StatusTracker) L1Head

func (st *StatusTracker) L1Head() eth.L1BlockRef

L1Head is a helper function; the L1 head is closely monitored for confirmation-distance logic.

func (*StatusTracker) OnCrossSafeUpdate added in v1.13.6

func (st *StatusTracker) OnCrossSafeUpdate(ctx context.Context, crossSafe eth.L2BlockRef, localSafe eth.L2BlockRef)

func (*StatusTracker) OnCrossUnsafeUpdate added in v1.13.6

func (st *StatusTracker) OnCrossUnsafeUpdate(ctx context.Context, crossUnsafe eth.L2BlockRef, localUnsafe eth.L2BlockRef)

func (*StatusTracker) OnEvent

func (st *StatusTracker) OnEvent(ctx context.Context, ev event.Event) bool

func (*StatusTracker) OnL1Finalized added in v1.13.6

func (st *StatusTracker) OnL1Finalized(x eth.L1BlockRef)

func (*StatusTracker) OnL1Safe added in v1.13.6

func (st *StatusTracker) OnL1Safe(x eth.L1BlockRef)

func (*StatusTracker) OnL1Unsafe added in v1.13.6

func (st *StatusTracker) OnL1Unsafe(x eth.L1BlockRef)

func (*StatusTracker) SyncStatus

func (st *StatusTracker) SyncStatus() *eth.SyncStatus

SyncStatus is thread safe, and reads the latest view of L1 and L2 block labels

func (*StatusTracker) UpdateSyncStatus added in v1.13.6

func (st *StatusTracker) UpdateSyncStatus()

Jump to

Keyboard shortcuts

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