blob

package
v0.0.0-...-a05e4c9 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2025 License: MIT, MIT Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Syncer

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

Syncer responsible for letting the L2 execution engine catching up with protocol's latest pending block through deriving L1 calldata.

func NewSyncer

func NewSyncer(
	ctx context.Context,
	client *rpc.Client,
	state *state.State,
	progressTracker *beaconsync.SyncProgressTracker,
	maxRetrieveExponent uint64,
	blobServerEndpoint *url.URL,
	socialScanEndpoint *url.URL,
) (*Syncer, error)

NewSyncer creates a new syncer instance.

func (*Syncer) InsertSoftBlockFromTransactionsBatch

func (s *Syncer) InsertSoftBlockFromTransactionsBatch(
	ctx context.Context,
	blockID uint64,
	batchID uint64,
	txListBytes []byte,
	batchMarker softblocks.TransactionBatchMarker,
	blockParams *softblocks.SoftBlockParams,
) (*types.Header, error)

InsertSoftBlockFromTransactionsBatch inserts a soft block into the L2 execution engine's blockchain from the given transactions batch.

func (*Syncer) ProcessL1Blocks

func (s *Syncer) ProcessL1Blocks(ctx context.Context) error

ProcessL1Blocks fetches all `TaikoL1.BlockProposed` events between given L1 block heights, and then tries inserting them into L2 execution engine's blockchain.

func (*Syncer) RemoveSoftBlocks

func (s *Syncer) RemoveSoftBlocks(ctx context.Context, newLastBlockID uint64) error

RemoveSoftBlocks removes soft blocks from the L2 execution engine's blockchain.

Jump to

Keyboard shortcuts

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