Skip to content

Commit 6233232

Browse files
committed
Fix backfill missing blocks in staging
1 parent e35ff76 commit 6233232

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

internal/orchestrator/committer.go

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -631,18 +631,7 @@ func (c *Committer) handleGap(ctx context.Context, expectedStartBlockNumber *big
631631
}
632632

633633
func (c *Committer) handleMissingStagingData(ctx context.Context, blocksToCommit []*big.Int) {
634-
// Checks if there are any blocks in staging after the current range end
635-
lastStagedBlockNumber, err := c.storage.StagingStorage.GetLastStagedBlockNumber(c.rpc.GetChainID(), blocksToCommit[len(blocksToCommit)-1], big.NewInt(0))
636-
if err != nil {
637-
log.Error().Err(err).Msg("Error checking staged data for missing range")
638-
return
639-
}
640-
if lastStagedBlockNumber == nil || lastStagedBlockNumber.Sign() <= 0 {
641-
log.Debug().Msgf("Committer is caught up with staging. No need to poll for missing blocks.")
642-
return
643-
}
644634
log.Debug().Msgf("Detected missing blocks in staging data starting from %s.", blocksToCommit[0].String())
645-
646635
blocksToPoll := blocksToCommit
647636
if len(blocksToCommit) > int(c.poller.blocksPerPoll) {
648637
blocksToPoll = blocksToCommit[:int(c.poller.blocksPerPoll)]

0 commit comments

Comments
 (0)