Skip to content

Bitcoin Header-Only Import Design #3922

@jolestar

Description

@jolestar

Summary

Change Rooch's Bitcoin block synchronization from importing full blocks to importing only block headers. This significantly reduces state bloat while maintaining the ability to verify Bitcoin transactions through Merkle proofs.

Problem

Currently, Rooch imports every Bitcoin block through the relayer and maps all UTXOs to Move objects. This causes:

  • Severe State Bloat: Bitcoin has hundreds of millions of UTXOs, each stored as an independent Move object
  • High Execution Cost: Every transaction must be executed, creating/destroying UTXO objects
  • Slow Synchronization: Processing complete transaction data is time-consuming

Proposed Solution

  1. Import Only Headers: Sync only block headers to drive time updates on Rooch network
  2. Merkle Verification: Verify specific transactions exist in blocks via Merkle proofs
  3. On-Demand State Creation: Create UTXO/Inscription objects only when needed

Design Document

See: docs/dev-guide/bitcoin_header_only_import_design.md


This is a tracking issue for the overall design. Sub-issues will be created for each implementation phase.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions