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

Separate LeafNodes from values #77

Merged
merged 2 commits into from
Feb 21, 2023

Conversation

preston-evans98
Copy link
Collaborator

Separate LeafNodes from values

This PR removes the value field from LeafNode, allowing values to be handled separately in the underlying data store. This allows very efficent get operations, since the tree no longer needs to be traversed in order to find the value of a given key. The tree is still traversed if a proof is requested.

Copy link
Contributor

@plaidfinch plaidfinch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have not tested this, but it looks solid and clearly written. This will be a breaking change to the external API, right? We should make a parallel PR on the Penumbra repo implementing the changes necessary to comply with this.

This commit removes the `value` field from `LeafNode`, allowing
values to be handled separately in the underlying data store. This
allows very efficent `get` operations, since the tree no longer
needs to be traversed in order to find the value of a given key.
The tree is still traversed if a proof is requested.
@preston-evans98 preston-evans98 merged commit 5fec679 into penumbra-zone:main Feb 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Testnet 45: Meti
Development

Successfully merging this pull request may close these issues.

2 participants