Technical Design
RollupDriver interface, L2 staged sync pipeline, chain config, and implementation phases
RollupDriver Interface
// rollup/driver.go
type Driver interface {
node.Lifecycle // Start() / Stop()
Type() DriverType // "optimistic", "zk", "based", "native", "consensus"
}Driver
├── DerivationPipeline — converts L1 data into L2 blocks (optimistic, zk, based)
├── Bridge — cross-chain message passing (deposits, withdrawals)
├── Sequencer — produces L2 blocks (sequencer mode only)
├── Prover — generates validity proofs (zk only)
├── L1DataSource — reads L1 state (direct in combined mode, RPC in l2-only)
└── L2Caplin — embedded CL instance for consensus rollupstype Ethereum struct {
// ... existing L1 fields unchanged ...
rollupDriver rollup.Driver // nil for pure L1
l1DataSource rollup.L1DataSource // direct or RPC-based
l2ChainDB kv.TemporalRwDB // separate L2 database
l2ExecModule *execmodule.ExecModule // separate L2 execution pipeline
}Polygon/Bor as the First Driver
L1DataSource
Implementation
Mode
Mechanism
L2 Staged Sync Pipeline
Stage
Source
Notes
Chain Configuration Extension
Native Rollups: Special Case
RPC Multi-Chain Routing
Implementation Phases
Phase
Scope
Key Files
File
Role
Last updated