Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: accumulated block data bitmap now contains current stxo indexes (#…
…3109) <!--- Provide a general summary of your changes in the Title above --> ## Description <!--- Describe your changes in detail --> Greatly reduces the amount of data stored per block by only storing the spent indexes at a specific height instead of the entire spent bitmap. The block chain database now stores a single full deleted bitmap at the tip. Breaking changes: - [x] Blockchain Database (database must be reynced) - [ ] Blockchain Consensus (hard/soft fork) - [ ] P2P Network (some protocols are no longer compatible) - [ ] GRPC (GRPC clients need to be updated) ## Motivation and Context <!--- Why is this change required? What problem does it solve? --> <!--- If it fixes an open issue, please link to the issue here. --> Bytes of storage per block reduced. At height 8033, the savings are 130mb on the new database. As the STXO set increases, the size of the deleted bitmap typically increases (depends on compressibility of the data in the bitmap), previously resulting in many megabytes of data per block. This is no longer the case. As a result of only having the tip bitmap, we can only calculate the output_mr for the next block from the tip. In practice this is all that is needed, however some unit tests needed to be updated. ## How Has This Been Tested? <!--- Please describe in detail how you tested your changes. --> <!--- Include details of your testing environment, and the tests you ran to --> <!--- see how your change affects other areas of the code, etc. --> - Some unit tests updated. - Base node archival sync - Currently not able to test pruned sync since it is broken (#3082) - Mined monero and sha3 blocks ## Checklist: <!--- Go over all the following points, and put an `x` in all the boxes that apply. --> * [x] I'm merging against the `development` branch. * [x] I have squashed my commits into a single commit. BREAKING CHANGE: Blockchain Database (database must be resynced)
- Loading branch information
Showing
13 changed files
with
270 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.