Add provider function to return a list of all stages and their progress #9649
Labels
A-db
Related to the database
C-enhancement
New feature or request
D-good-first-issue
Nice and easy! A great choice to get started
Describe the feature
with alloy-rs/alloy#1079 we can now emit an list of stages and their processed blocks
which can be obtained from the
reth/crates/storage/storage-api/src/stage_checkpoint.rs
Lines 5 to 9 in 9e68516
we need a new function here that returns a list of all checkpoints in that table:
we need to iterate over this table and decode its keys to string and the checkpoint
reth/crates/storage/provider/src/providers/database/provider.rs
Lines 2507 to 2509 in 9e68516
TODO
this can be done via
reth/crates/storage/db-api/src/transaction.rs
Line 22 in 9e68516
and then walk
reth/crates/storage/db-api/src/cursor.rs
Line 40 in 9e68516
FYI @loocapro
Additional context
No response
The text was updated successfully, but these errors were encountered: