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

Move append into AccountStorageEntry #3172

Closed

Conversation

sakridge
Copy link
Member

@sakridge sakridge commented Mar 7, 2019

Problem

Seems like AccountStorageEntry object which holds the AppendVec will know when the storage is full or not.

Summary of Changes

Move append into new AccountStorageEntry::append_account function, handle the count and status there.

Fixes #

@sakridge sakridge requested a review from sambley March 7, 2019 02:40
@sakridge
Copy link
Member Author

sakridge commented Mar 7, 2019

@sambley is this right? Seems like we should not update the count when we do insert_account_entry, when we do that in squash. There we increment the count, but we didn't actually append anything, just created another index for it on another fork.

@sambley
Copy link
Contributor

sambley commented Mar 7, 2019

@sambley is this right? Seems like we should not update the count when we do insert_account_entry, when we do that in squash. There we increment the count, but we didn't actually append anything, just created another index for it on another fork.

We would have 2 index entries (one in parent fork and other in squashed fork) both pointing to the same entry as we are not moving it right? The increment was to account for the new index entry being added to the fork.

@sakridge
Copy link
Member Author

sakridge commented Mar 7, 2019

@sambley I see, it's like a reference count of all items in the appendvec.

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

Successfully merging this pull request may close these issues.

2 participants