mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-25 05:55:42 +00:00
Improve docs on --keep-blocks CLI parameter and related data structures (#11611)
* Improve docs on `--keep-blocks` CLI parameter and related data structures * Update client/db/src/lib.rs Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com> Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
This commit is contained in:
@@ -33,6 +33,8 @@ pub struct PruningParams {
|
|||||||
/// Specify the number of finalized blocks to keep in the database.
|
/// Specify the number of finalized blocks to keep in the database.
|
||||||
///
|
///
|
||||||
/// Default is to keep all blocks.
|
/// Default is to keep all blocks.
|
||||||
|
///
|
||||||
|
/// NOTE: only finalized blocks are subject for removal!
|
||||||
#[clap(long, value_name = "COUNT")]
|
#[clap(long, value_name = "COUNT")]
|
||||||
pub keep_blocks: Option<u32>,
|
pub keep_blocks: Option<u32>,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -302,6 +302,8 @@ pub struct DatabaseSettings {
|
|||||||
/// Where to find the database.
|
/// Where to find the database.
|
||||||
pub source: DatabaseSource,
|
pub source: DatabaseSource,
|
||||||
/// Block pruning mode.
|
/// Block pruning mode.
|
||||||
|
///
|
||||||
|
/// NOTE: only finalized blocks are subject for removal!
|
||||||
pub keep_blocks: KeepBlocks,
|
pub keep_blocks: KeepBlocks,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -667,6 +667,8 @@ impl<B: BlockT> warp_request_handler::WarpSyncProvider<B> for TestWarpSyncProvid
|
|||||||
#[derive(Default)]
|
#[derive(Default)]
|
||||||
pub struct FullPeerConfig {
|
pub struct FullPeerConfig {
|
||||||
/// Pruning window size.
|
/// Pruning window size.
|
||||||
|
///
|
||||||
|
/// NOTE: only finalized blocks are subject for removal!
|
||||||
pub keep_blocks: Option<u32>,
|
pub keep_blocks: Option<u32>,
|
||||||
/// Block announce validator.
|
/// Block announce validator.
|
||||||
pub block_announce_validator: Option<Box<dyn BlockAnnounceValidator<Block> + Send + Sync>>,
|
pub block_announce_validator: Option<Box<dyn BlockAnnounceValidator<Block> + Send + Sync>>,
|
||||||
|
|||||||
@@ -77,6 +77,8 @@ pub struct Configuration {
|
|||||||
/// State pruning settings.
|
/// State pruning settings.
|
||||||
pub state_pruning: Option<PruningMode>,
|
pub state_pruning: Option<PruningMode>,
|
||||||
/// Number of blocks to keep in the db.
|
/// Number of blocks to keep in the db.
|
||||||
|
///
|
||||||
|
/// NOTE: only finalized blocks are subject for removal!
|
||||||
pub keep_blocks: KeepBlocks,
|
pub keep_blocks: KeepBlocks,
|
||||||
/// Chain configuration.
|
/// Chain configuration.
|
||||||
pub chain_spec: Box<dyn ChainSpec>,
|
pub chain_spec: Box<dyn ChainSpec>,
|
||||||
|
|||||||
Reference in New Issue
Block a user