mirror of
https://gitlab.com/pulsechaincom/lighthouse-pulse.git
synced 2025-01-05 18:42:20 +00:00
Prune blobs in bg after canonical head update
This commit is contained in:
parent
8752deeced
commit
2f565d25b2
@ -793,6 +793,19 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
||||
.execution_status
|
||||
.is_optimistic_or_invalid();
|
||||
|
||||
if self.store.get_config().prune_blobs {
|
||||
let store = self.store.clone();
|
||||
let log = self.log.clone();
|
||||
self.task_executor.spawn_blocking(
|
||||
move || {
|
||||
if let Err(e) = store.try_prune_blobs(false) {
|
||||
error!(log, "Error pruning blobs in background"; "error" => ?e);
|
||||
}
|
||||
},
|
||||
"prune_blobs_background",
|
||||
);
|
||||
}
|
||||
|
||||
// Detect and potentially report any re-orgs.
|
||||
let reorg_distance = detect_reorg(
|
||||
&old_snapshot.beacon_state,
|
||||
|
Loading…
Reference in New Issue
Block a user