Plumb maximum_incremental_snapshot_archives_to_retain (#19640)

This commit is contained in:
Brooks Prumo
2021-09-06 18:01:56 -05:00
committed by GitHub
parent 37fe5139cc
commit 9d9482b9d8
9 changed files with 69 additions and 32 deletions

View File

@ -54,6 +54,7 @@ impl SnapshotPackagerService {
snapshot_utils::archive_snapshot_package(
&snapshot_package,
snapshot_config.maximum_full_snapshot_archives_to_retain,
snapshot_config.maximum_incremental_snapshot_archives_to_retain,
)
.expect("failed to archive snapshot package");
@ -190,6 +191,7 @@ mod tests {
snapshot_utils::archive_snapshot_package(
&snapshot_package,
snapshot_utils::DEFAULT_MAX_FULL_SNAPSHOT_ARCHIVES_TO_RETAIN,
snapshot_utils::DEFAULT_MAX_INCREMENTAL_SNAPSHOT_ARCHIVES_TO_RETAIN,
)
.unwrap();

View File

@ -1238,6 +1238,7 @@ fn new_banks_from_ledger(
&snapshot_config.snapshot_archives_dir,
snapshot_config.archive_format,
snapshot_config.maximum_full_snapshot_archives_to_retain,
snapshot_config.maximum_incremental_snapshot_archives_to_retain,
)
.unwrap_or_else(|err| {
error!("Unable to create snapshot: {}", err);