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

prune trie nodes from database #1361

Closed
noot opened this issue Feb 5, 2021 · 1 comment
Closed

prune trie nodes from database #1361

noot opened this issue Feb 5, 2021 · 1 comment
Assignees

Comments

@noot
Copy link
Contributor

noot commented Feb 5, 2021

Task summary

  • currently, we never prune trie nodes from the database
  • there are 2 cases we want to remove nodes from the database: 1. when a chain is finalized, we want to delete any nodes that are in non-finalized forks but are not in the canonical chain; 2. if we are not an "archive node" we want to delete any nodes from blocks earlier than some block in the chain, that are not being used by any blocks higher than that.
  • this issue is to determine when a trie node and its child nodes are no longer used, and to then delete them from the database
  • reference counting is a possible solution, but needs more research
@dutterbutter
Copy link
Contributor

Initial research for this issue -> https://hackmd.io/NYtcmdM_QVanSVfTyKbssg

We will start with implementing offline bloom filters.

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

No branches or pull requests

3 participants