Skip to content

Commit

Permalink
exporter: only update status of last 10 epochs when there are finalit…
Browse files Browse the repository at this point in the history
…y-issues
  • Loading branch information
guybrush committed Oct 22, 2020
1 parent 6cc44e9 commit f81fe2d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions exporter/exporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,9 @@ func Start(client rpc.Client) error {
startEpoch = uint64(0)
if head.FinalizedEpoch > 10 {
startEpoch = head.FinalizedEpoch - 10
if head.HeadEpoch-startEpoch > 10 {
startEpoch = head.HeadEpoch - 10
}
}
logger.Infof("updating status of epochs %v-%v", startEpoch, head.HeadEpoch)
err = updateEpochStatus(client, startEpoch, head.HeadEpoch)
Expand Down

0 comments on commit f81fe2d

Please sign in to comment.