-
Notifications
You must be signed in to change notification settings - Fork 102
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
change(state): Set upper bound when reading from deleting column family tx_loc_by_transparent_addr_loc #7732
Conversation
zebra-state/src/service/finalized_state/zebra_db/transparent.rs
Outdated
Show resolved
Hide resolved
zebra-state/src/service/finalized_state/zebra_db/transparent.rs
Outdated
Show resolved
Hide resolved
zebra-state/src/service/finalized_state/zebra_db/transparent.rs
Outdated
Show resolved
Hide resolved
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.
This is good except for an incorrect constant (which is currently technically valid due to a workaround in other code).
The names here could do with some changes to avoid confusion when we modify this code again, but that is optional.
zebra-state/src/service/finalized_state/zebra_db/transparent.rs
Outdated
Show resolved
Hide resolved
zebra-state/src/service/finalized_state/disk_format/transparent.rs
Outdated
Show resolved
Hide resolved
zebra-state/src/service/finalized_state/disk_format/transparent.rs
Outdated
Show resolved
Hide resolved
zebra-state/src/service/finalized_state/disk_format/transparent.rs
Outdated
Show resolved
Hide resolved
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.
Thank you! I think the changes are good, but the documentation is now outdated.
Can you also update the PR title? There aren't any read bounds being set in this PR, it's just a refactor that allows them to be set in the next PR. It might also help to use the name of the column family or RPC, because there's just one of them. |
@Mergifyio refresh |
✅ Pull request refreshed |
Motivation
This PR updates
address_transaction_locations()
to avoid using multiple iterators to read data from disk and to set an upper iterate bound.This function is currently used by
zebra-rpc
for theget_address_tx_ids
method.Part of #7664.
Solution
address_transaction_locations()
to usezs_range_iter
instead ofzs_next_key_value_from
Related cleanups:
rpc_getaddresstxids_response
Review
Anyone can review.
Reviewer Checklist