Add high level overview comments on ledger_cleanup_service (#24184)

This commit is contained in:
steviez 2022-04-08 00:49:21 -05:00 committed by GitHub
parent e105547c14
commit 1dd63631c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -1,4 +1,8 @@
//! The `ledger_cleanup_service` drops older ledger data to limit disk space usage
//! The `ledger_cleanup_service` drops older ledger data to limit disk space usage.
//! The service works by counting the number of live data shreds in the ledger; this
//! can be done quickly and should have a fairly stable correlation to actual bytes.
//! Once the shred count (and thus roughly the byte count) reaches a threshold,
//! the services begins removing data in FIFO order.
use {
crossbeam_channel::{Receiver, RecvTimeoutError},