-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
fix(chainwatch): use height to determine unsynced blocks and fix deadlock in sector deal table #3275
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't merge. Testing with this causes sync to walk the whole chain over and over. Need to review the behavior before merging.
d1e488e
to
3f165cc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One bug, a few logging nits. Probably should also flatten this PR given all the back and forth within.
@@ -214,7 +205,7 @@ func (p *Processor) Start(ctx context.Context) { | |||
if err := p.refreshViews(); err != nil { | |||
log.Errorw("Failed to refresh views", "error", err) | |||
} | |||
log.Infow("Processed Batch", "duration", time.Since(loopStart).String()) | |||
log.Infow("PROCESSED BATCH COMPLETE", "duration", time.Since(loopStart).String()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to yell.
291e4e4
to
629b5c2
Compare
629b5c2
to
f934ebd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look GTM.
This table may get multiple updates depending on how many blocks get added into a tipset. Each new block affects the tipset state, but the parent state root will remain the same. This allows the very latest value to be applied.
…wer-reward-metrics feat(chainwatch): Add more complete power and reward metrics
We were detecting syncing problems with chainwatch which ended up being caused by race condition. This resolves the race condition and improve the sync alogrithm so last synced block is more determistically determined by height rather than by time.