Skip to content

feat: adr & Impl: lazy aggregation - #2224

Merged
tac0turtle merged 25 commits into
mainfrom
marko/lazy-aggregation-adr
May 5, 2025
Merged

feat: adr & Impl: lazy aggregation#2224
tac0turtle merged 25 commits into
mainfrom
marko/lazy-aggregation-adr

Conversation

@tac0turtle

@tac0turtle tac0turtle commented Apr 29, 2025

Copy link
Copy Markdown
Contributor

Overview

This ADR proposes a solution for maintaining consistency between DA layer blocks and execution layer blocks during periods of inactivity in Rollkit's lazy aggregation mechanism.

Currently, empty blocks are skipped on the DA layer, breaking the 1:1 block mapping expected by EVM environments. The proposed solution introduces a minimal sentinel transaction for empty blocks, ensuring consistent block heights while minimizing DA costs.

closes #2193

TL;DR:

  • Introduces sentinel markers for empty blocks on DA layer
  • Maintains block height consistency for EVM compatibility
  • Optimizes DA space usage with minimal 3-byte markers
  • Preserves existing lazy aggregation performance

Summary by CodeRabbit

  • Documentation
    • Added a new architecture decision record (ADR) outlining the approach for handling empty blocks to ensure consistent block height mapping between Rollkit and the Data Availability layer. The document details the mechanism for signaling empty blocks, maintaining timing information, and ensuring reliable syncing.
  • New Features
    • Introduced lazy aggregation mode with dual timers to produce blocks regularly during inactivity and promptly when transactions arrive.
    • Enabled creation and publishing of empty blocks to maintain consistent block timing and height mapping.
    • Added transaction notification signaling to trigger timely block production.
  • Bug Fixes
    • Improved block production logic to preserve proper timing and deterministic block creation even when no transactions are present.
  • Tests
    • Added comprehensive unit tests covering lazy aggregation behavior, timer interactions, empty block creation, and transaction notification handling.
  • Chores
    • Renamed configuration flags and fields for lazy mode and block interval for clarity and consistency.
    • Linked transaction reaper component with block manager to notify on new transactions.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] lazy aggregation with latest sequencing/execution changes

4 participants