-
Notifications
You must be signed in to change notification settings - Fork 4.7k
[wip] Add rocksdb's kv dump subcommand #26330
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -188,6 +188,10 @@ fn output_slot( | |
verbose_level: u64, | ||
all_program_ids: &mut HashMap<Pubkey, u64>, | ||
) -> Result<(), String> { | ||
for (key, value) in blockstore.dump(slot) { | ||
println!("{} {}", key.iter().map(|k| format!("{:02X}", k)).join(""), value.iter().map(|v| format!("{:02X}", v)).join("")); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ideally, this should be matched to this pr's output:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. hmm, my memory is vague. but iirc, there was some way to adjust There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. or, i just There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. anyway, the basic idea is that using the same format makes detecting bitrot a piece of case by There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. the below is the extended |
||
} | ||
|
||
if blockstore.is_dead(slot) { | ||
if allow_dead_slots { | ||
if *method == LedgerOutputMethod::Print { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
obviously, this isn't good to merge as-is.
Ideally, we should add new ledger-tool subcommand like this: