-
Notifications
You must be signed in to change notification settings - Fork 37.7k
wallet: move BDB specific classes to bdb.{cpp/h} #19290
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
Conversation
Put the implementation in the cpp, not the h file.
Leave wallet/db.{cpp/h} for generic WalletDatabase stuff. The BDB specific stuff goes into bdb.{cpp/h}
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
Code review ACK 61c1633 |
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.
utACK 61c1633
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.
Code review ACK 61c1633
…Exists functions into non-template functions a389ed5 walletdb: refactor Read, Write, Erase, and Exists into non-template func (Andrew Chow) Pull request description: In order to override these later, the specific details of how the Read, Write, Erase, and Exists functions interact with the actual database file need to go into functions that are not templated. The functions `ReadKey`, `WriteKey`, `EraseKey`, and `HasKey` are introduced to handle the actual interaction with the database. This is mostly a moveonly. Based on #19290 ACKs for top commit: ryanofsky: Code review ACK a389ed5. No changes since last review, just non-conflicting rebase Sjors: utACK a389ed5 MarcoFalke: ACK a389ed5 🔳 Tree-SHA512: 73bd2fe9ddc4a132d4db6b97e77f5d5f8aa68b8cb25192384f3bacd826365947763a9eee73672331d34578e3f5ade85ee6aa550ff4d89eb62e482250dd5973e4
Summary: Partial backport (1/5) of core [[bitcoin/bitcoin#19290 | PR19290]]: bitcoin/bitcoin@c3538f4 Test Plan: ninja all check Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Differential Revision: https://reviews.bitcoinabc.org/D8611
Summary: Partial backport (2/5) of core [[bitcoin/bitcoin#19290 | PR19290]]: bitcoin/bitcoin@f6fc5f3 Depends on D8611. Test Plan: ninja all check Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Differential Revision: https://reviews.bitcoinabc.org/D8612
Summary: Partial backport (3/5) of core [[bitcoin/bitcoin#19290 | PR19290]]: bitcoin/bitcoin@25a6557 Depends on D8612. Test Plan: ninja all check Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Differential Revision: https://reviews.bitcoinabc.org/D8613
Summary: ``` Put the implementation in the cpp, not the h file. ``` Partial backport (4/5) of core [[bitcoin/bitcoin#19290 | PR19290]]: bitcoin/bitcoin@8f03364 Depends on D8613. Test Plan: ninja all check-all Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Differential Revision: https://reviews.bitcoinabc.org/D8614
Summary: ``` Leave wallet/db.{cpp/h} for generic WalletDatabase stuff. The BDB specific stuff goes into bdb.{cpp/h} ``` Completes backport (5/5) of core [[bitcoin/bitcoin#19290 | PR19290]]: bitcoin/bitcoin@61c1633 Depends on D8614. Test Plan: ninja all check-all Reviewers: #bitcoin_abc, majcosta Reviewed By: #bitcoin_abc, majcosta Subscribers: majcosta Differential Revision: https://reviews.bitcoinabc.org/D8615
Moves the BDB specific classes from db.{cpp/h} to bdb.{cpp/h}.
To do this,
SplitWalletFilePath
is first made non-static. ThenIsWalletLoaded
functionality is moved toIsBDBWalletLoaded
which is called byIsWalletLoaded
. Then the bulk of db.{cpp/h} is moved to a new file bdb.{cpp/h}.While doing some moveonly stuff, an additional commit moves the
*Cursor
andTxn*
implementations out of the header file and into the cpp file.Part of #18971