prysm icon indicating copy to clipboard operation
prysm copied to clipboard

WIP: External DB tool support

Open kasey opened this issue 2 years ago • 0 comments

What type of PR is this?

Other

What does this PR do? Why is it needed?

Allow code outside the db package to open the bolt database and hold a copy of the *bolt.DB handle. This enables code outside the kv package to have access to the underlying bolt db while also using kv.Store methods.

Supports building an IsCanonical value directly from the db using the finalized index instead of the forkchoice store. This is helpful to enable a program to utilize stategen.Replayer without running the full beacon node.

Other notes for review

I have a messy R&D branch for database optimization work which uses these changes. I am trying to split them out into a separate PR as a way of keeping a small delta with develop as I refactor and cherry pick useful changes from that branch.

kasey avatar Jul 20 '22 16:07 kasey