Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parallel fetch for chain sync #3887

Merged
merged 11 commits into from
Sep 23, 2020
Prev Previous commit
Next Next commit
clean up return code
  • Loading branch information
vyzo committed Sep 17, 2020
commit 2946561decdb7bd7b9056cc256c6e32294a13279
7 changes: 4 additions & 3 deletions chain/sync.go
Original file line number Diff line number Diff line change
Expand Up @@ -1593,11 +1593,12 @@ func (syncer *Syncer) fetchMessages(ctx context.Context, headers []*types.TipSet
}
wg.Wait()

if batchErr == nil {
dt := build.Clock.Since(start)
log.Infof("fetching messages for %d tipsets at %d done; took %s", batchSize, startOffset, dt)
if batchErr != nil {
return nil, batchErr
}

log.Infof("fetching messages for %d tipsets at %d done; took %s", batchSize, startOffset, build.Clock.Since(start))

return batch, batchErr
}

Expand Down