-
Notifications
You must be signed in to change notification settings - Fork 87
refactor [1/4]: change accounts db schema #1481
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
base: next
Are you sure you want to change the base?
Conversation
bobbinth
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Thank you! I reviewed most non-test code and left some small comments inline.
Overall, I think this structure works for now, but we'll probably need to re-think this shortly after the refactoring is merged as in many places the interactions with the database are likely to be prohibitively expensive.
bobbinth
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Thank you! I reviewed all non-test code and left one comment for the future inline.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not for this PR: this file is pretty large and difficult to navigate. I think we should break it up into a few smaller files which contain logically grouped functionality.
Preparation / carve out from #1394 since the feedback caused additional linecount -
nosome minor functional changes were made!A large chunk of the linecount are testcases
Core changes
schema.rs- move storage map into separate table, avoid storing full serialized account toaccountstable, move vault data to separate table (breaking)models/conv.rs-StorageSlotType- change DB representation (breaking)queries/at_block.rs- add new*_at_blockqueriesfn validate_block_exists