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

[checkpoint] local_fragments should be indexed on sequence number #4502

Merged
merged 1 commit into from
Sep 7, 2022

Conversation

lxfind
Copy link
Contributor

@lxfind lxfind commented Sep 7, 2022

local_fragments are currently indexed on AuthorityName, which means that fragments in it can be from any checkpoint. Although we empty the entire local_fragments table whenever we are forming a new checkpoint, fragments from previous checkpoints can still show up in local_fragments when a consensus message is delayed (i.e. receiving a fragment after the checkpoint is formed). And currently in all uses of local_fragments, we don't distinguish their checkpoint sequence number. This can lead to two issues: 1) we may be thinking that we have already fragmented with a validator, but in fact we haven't. 2) we may be using a fragment from previous checkpoint to construct a new checkpoint by thinking that there is a link to the spanning tree.

@lxfind lxfind force-pushed the checkout-local-fragment-add-seq branch from dceda2c to bca16cd Compare September 7, 2022 16:00
@lxfind lxfind marked this pull request as ready for review September 7, 2022 16:04
@lxfind lxfind merged commit 674d133 into main Sep 7, 2022
@lxfind lxfind deleted the checkout-local-fragment-add-seq branch September 7, 2022 21:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants