-
Notifications
You must be signed in to change notification settings - Fork 114
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
2. feat(db): Add address balance indexes to the finalized state #3963
Merged
Conversation
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
teor2345
added
A-dependencies
Area: Dependency file updates
C-enhancement
Category: This is an improvement
P-High 🔥
A-state
Area: State / database changes
do-not-merge
Tells Mergify not to merge this PR
lightwalletd
any work associated with lightwalletd
labels
Mar 25, 2022
teor2345
commented
Mar 25, 2022
...e/src/service/finalized_state/zebra_db/block/tests/snapshots/address_balances@testnet_1.snap
Show resolved
Hide resolved
teor2345
force-pushed
the
db-transaction-split
branch
from
March 27, 2022 23:59
cb0ee0c
to
adcff1e
Compare
teor2345
force-pushed
the
db-trans-balance
branch
from
March 27, 2022 23:59
01bf3d1
to
495f128
Compare
3 tasks
teor2345
force-pushed
the
db-transaction-split
branch
from
March 29, 2022 00:01
adcff1e
to
5d3181c
Compare
teor2345
force-pushed
the
db-trans-balance
branch
from
March 29, 2022 00:03
495f128
to
eefcd82
Compare
teor2345
requested review from
upbqdn and
oxarbitrage
and removed request for
upbqdn
March 29, 2022 20:49
teor2345
force-pushed
the
db-transaction-split
branch
from
March 29, 2022 23:06
5d3181c
to
6f28aa8
Compare
teor2345
force-pushed
the
db-trans-balance
branch
from
March 29, 2022 23:06
eefcd82
to
7c0eb23
Compare
teor2345
force-pushed
the
db-transaction-split
branch
from
March 31, 2022 01:20
6f28aa8
to
26a4de5
Compare
teor2345
force-pushed
the
db-trans-balance
branch
from
March 31, 2022 01:20
7c0eb23
to
c07681c
Compare
teor2345
force-pushed
the
db-transaction-split
branch
from
April 4, 2022 00:27
26a4de5
to
4a047a6
Compare
teor2345
force-pushed
the
db-trans-balance
branch
from
April 4, 2022 00:27
c07681c
to
9604d84
Compare
teor2345
added
do-not-merge
Tells Mergify not to merge this PR
and removed
do-not-merge
Tells Mergify not to merge this PR
labels
Apr 4, 2022
4 tasks
It was actually just the UTXOs from the state spent by the block, excluding the UTXOs created and spent within the block. But now we need it to contain all the spent outputs, including the ones created by the block.
conradoplg
force-pushed
the
db-trans-balance
branch
from
April 7, 2022 14:53
9604d84
to
a602758
Compare
Rebased after base PR was merged |
conradoplg
approved these changes
Apr 7, 2022
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
19 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-dependencies
Area: Dependency file updates
A-state
Area: State / database changes
C-enhancement
Category: This is an improvement
lightwalletd
any work associated with lightwalletd
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
AddressLocation
) for the rest of the address indexesDesigns
The
balance_by_transparent_addr
and address types parts of:https://github.com/ZcashFoundation/zebra/blob/main/book/src/dev/rfcs/0005-state-updates.md#rocksdb-data-structures
Solution
Database Changes:
Related Refactors:
Related Tests:
(My local full syncs worked successfully, the database now takes ~35 GB.)
I ran a manual full sync test here:
It got to 98.925% after 6 hours, which is acceptable performance.
Closes #3950.
Review
This PR is on the critical path for the lightwalletd work, so I've tagged it as a high priority.
This is unrelated to previous PRs, so I'll pick a random reviewer.
This PR is based on PR #3934.
Reviewer Checklist
Follow Up Work
The rest of the database changes.