signet-cold-mdbx
MDBX backend implementation for cold storage.
This crate provides table definitions and an MDBX-based backend for storing historical blockchain data.
Tables
Primary Data Tables
| Table | Key | Value |
|---|---|---|
ColdHeaders |
Block number | Header |
ColdTransactions |
(Block number, tx index) | Transaction |
ColdReceipts |
(Block number, tx index) | Receipt |
ColdSignetEvents |
(Block number, event index) | Signet event |
ColdZenithHeaders |
Block number | Zenith header |
Index Tables
| Table | Key | Value |
|---|---|---|
ColdBlockHashIndex |
Block hash | Block number |
ColdTxHashIndex |
Tx hash | (Block number, tx index) |
Metadata Tables
| Table | Key | Value |
|---|---|---|
ColdMetadata |
Metadata key | Block number |
Metadata keys: Latest, Finalized, Safe, Earliest.
Usage
use ;
// Open database
let backend = open?;
// Use with cold storage task
let = new;
spawn;
Re-exports
DatabaseArguments,DatabaseEnvKindfromsignet-hot-mdbx