Skip to content

go/oasis-node: Add new storage inspect command #6427

@martintomazic

Description

@martintomazic

Add new oasis-node storage inspect command that displays last retained and latest version for all databases.

E.g.:

Consensus:
    State DB:
        Latest height: [uin64]
        Last retained height: [uin64]
    Block store/history: 
        Latest height: [uin64]
        Last retained height: [uin64]
Runtimes:
    000000000000000000000000000000000000000000000000f80306c9858e7279:
        State DB:
            Latest round: [uin64]
            Last retained round: [uin64]
        Light History:
             Latest round: [uin64]
             Last retained round: [uin64]         

Motivation

Currently to obtain this you need to start the node.

There are cases where you want you data to be static, moreover it takes time for node to actually sync and display this info. Finally, for such simple query you don't want to possibly register and or start serving p2p to then stop the node.

Use cases:

Implementation space

Add to go/oasis-node/cmd/storage.

Should be "trivial" as we already have helpers there for manually opening databases (with exact same config the actual node has).

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions