Skip to content

Commit

Permalink
Merge pull request #5342 from oasisprotocol/ptrus/fix/storage-sync-ba…
Browse files Browse the repository at this point in the history
…ckoff2

storage/sync: don't immediately trigger more round fetches on failures
  • Loading branch information
ptrus authored Aug 9, 2023
2 parents 6003203 + 77211dc commit 7e75db2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions .changelog/5326.bugfix.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
storage/sync: don't immediately trigger more round fetches on failures
6 changes: 4 additions & 2 deletions go/worker/storage/committee/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -1247,10 +1247,12 @@ mainLoop:
syncingRounds[item.round].retry(item.thisRoot.Type)
} else {
heap.Push(outOfOrderDoneDiffs, item)
// Item was successfully processed, trigger more round fetches.
// This ensures that new rounds are processed as fast as possible
// when we're syncing and are far behind.
triggerRoundFetches()
}

triggerRoundFetches()

case finalized := <-n.finalizeCh:
// If finalization failed, things start falling apart.
// There's no point redoing it, since it's probably not a transient
Expand Down

0 comments on commit 7e75db2

Please sign in to comment.