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

merkledb -- nits #1916

Merged
merged 4 commits into from
Aug 24, 2023
Merged

merkledb -- nits #1916

merged 4 commits into from
Aug 24, 2023

Conversation

danlaine
Copy link

Why this should be merged

Cleanup

How this works

Comments

How this was tested

N/A

@danlaine danlaine added cleanup Code quality improvement merkledb labels Aug 24, 2023
@danlaine danlaine self-assigned this Aug 24, 2023
Comment on lines -10 to -11
// batch is a write-only database that commits changes to its host database
// when Write is called.
Copy link
Author

Choose a reason for hiding this comment

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

This is documented on database.Batch so no need to do it here

type batch struct {
database.BatchOps

db *merkleDB
}

// apply all operations in order to the database and write the result to disk
func (b *batch) Write() error {
Copy link
Author

Choose a reason for hiding this comment

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

This is documented on database.Batch so no need to do it here

Comment on lines +79 to +80
// - When the changes in [proof.KeyChanes] are applied,
// the root ID of the database is [expectedEndRootID].
Copy link
Author

Choose a reason for hiding this comment

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

proof.KeyValues and proof.DeletedKeys no longer exist

Comment on lines +983 to +984
// This is defined on merkleDB instead of ChangeProof
// because it accesses database internals.
Copy link
Author

Choose a reason for hiding this comment

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

Moved from ChangeProofer spec

@danlaine danlaine merged commit 7bf4955 into dev Aug 24, 2023
16 checks passed
@danlaine danlaine deleted the merkledb-nits-2 branch August 24, 2023 17:50
@danlaine danlaine added this to the v1.10.10 milestone Sep 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Code quality improvement merkledb
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants