mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-04-30 03:01:58 -04:00
Co-authored-by: Bjerg <onbjerg@users.noreply.github.com> Co-authored-by: Roman Krasiuk <rokrassyuk@gmail.com> Co-authored-by: joshieDo <ranriver@protonmail.com> Co-authored-by: joshieDo <93316087+joshieDo@users.noreply.github.com> Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de> Co-authored-by: Oliver Nordbjerg <hi@notbjerg.me> Co-authored-by: Thomas Coratger <thomas.coratger@gmail.com>
16 lines
520 B
Rust
16 lines
520 B
Rust
use reth_primitives::{BlockNumber, PruneProgress, PruneSegment};
|
|
use std::{collections::BTreeMap, time::Duration};
|
|
|
|
/// An event emitted by a [Pruner][crate::Pruner].
|
|
#[derive(Debug, PartialEq, Eq, Clone)]
|
|
pub enum PrunerEvent {
|
|
/// Emitted when pruner started running.
|
|
Started { tip_block_number: BlockNumber },
|
|
/// Emitted when pruner finished running.
|
|
Finished {
|
|
tip_block_number: BlockNumber,
|
|
elapsed: Duration,
|
|
stats: BTreeMap<PruneSegment, (PruneProgress, usize)>,
|
|
},
|
|
}
|