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

Persist fork-choice state > start from head #4000

Open
3 tasks
dapplion opened this issue May 10, 2022 · 2 comments
Open
3 tasks

Persist fork-choice state > start from head #4000

dapplion opened this issue May 10, 2022 · 2 comments
Labels
prio-low This is nice to have. scope-ux Issues for CLI UX or general consumer UX.

Comments

@dapplion
Copy link
Contributor

dapplion commented May 10, 2022

Currently Lodestar follow the simpler strategy (1) on start-up to just consider the latest finalized state as the head. Then sync all blocks from finalized state to head from our peers, and re-populate fork-choice graph.

Another strategy (2) is to persist the fork-choice state (on shutdown and / or periodically) and restore that state on startup. This approach will prevent "reverting" the head to a much older state. This caused:

TODO:

  • Research what each other client is doing
  • Estimate the positives of strategy (2) vs (1), specially in periods of long non-finality
  • Estimate the complexity of strategy (2) vs (1), and the cost of persisting this data + pruning.

Only if it's clear that positives >> complexity + cost, consider implementing.

@dapplion dapplion added prio-low This is nice to have. meta-discussion Indicates a topic that requires input from various developers. scope-security Issues that fix security issues: DOS, key leak, CVEs. scope-ux Issues for CLI UX or general consumer UX. labels May 10, 2022
@g11tech
Copy link
Contributor

g11tech commented Jul 2, 2022

my 2 cents: I actually like that we got, helps us recover lots of random scenarios by restarting, especially where local EL can be buggy in post-merge world by having this easy option to step back.

@wemeetagain
Copy link
Member

👍 We should make sure this feature has an enable/disable flag

@philknows philknows removed meta-discussion Indicates a topic that requires input from various developers. scope-security Issues that fix security issues: DOS, key leak, CVEs. labels Nov 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
prio-low This is nice to have. scope-ux Issues for CLI UX or general consumer UX.
Projects
No open projects
Status: Todo
Development

No branches or pull requests

4 participants