File tree Expand file tree Collapse file tree 3 files changed +3
-2
lines changed
packages/beacon-node/src/chain/archiver Expand file tree Collapse file tree 3 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -64,7 +64,7 @@ export class Archiver {
6464
6565 /** Archive latest finalized state */
6666 async persistToDisk ( ) : Promise < void > {
67- return this . statesArchiverStrategy . maybeArchiveState ( this . chain . forkChoice . getFinalizedCheckpoint ( ) ) ;
67+ return this . statesArchiverStrategy . archiveState ( this . chain . forkChoice . getFinalizedCheckpoint ( ) ) ;
6868 }
6969
7070 private onFinalizedCheckpoint = async ( finalized : CheckpointWithHex ) : Promise < void > => {
Original file line number Diff line number Diff line change @@ -44,4 +44,5 @@ export interface StateArchiveStrategy {
4444 onCheckpoint ( stateRoot : RootHex , metrics ?: Metrics | null ) : Promise < void > ;
4545 onFinalizedCheckpoint ( finalized : CheckpointWithHex , metrics ?: Metrics | null ) : Promise < void > ;
4646 maybeArchiveState ( finalized : CheckpointWithHex , metrics ?: Metrics | null ) : Promise < void > ;
47+ archiveState ( finalized : CheckpointWithHex , metrics ?: Metrics | null ) : Promise < void > ;
4748}
Original file line number Diff line number Diff line change @@ -84,7 +84,7 @@ export class FrequencyStateArchiveStrategy implements StateArchiveStrategy {
8484 * Archives finalized states from active bucket to archive bucket.
8585 * Only the new finalized state is stored to disk
8686 */
87- private async archiveState ( finalized : CheckpointWithHex , metrics ?: Metrics | null ) : Promise < void > {
87+ async archiveState ( finalized : CheckpointWithHex , metrics ?: Metrics | null ) : Promise < void > {
8888 // starting from Mar 2024, the finalized state could be from disk or in memory
8989 const finalizedStateOrBytes = await this . regen . getCheckpointStateOrBytes ( finalized ) ;
9090 const { rootHex} = finalized ;
You can’t perform that action at this time.
0 commit comments