Retire the db-4.8.30 build dependency without porting descriptor wallets #44
Labels
No labels
do-not-open-till-X-Day
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
SubGeniusFinance/dobbscoin-source#44
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Split out of #41, which bundles two jobs of very different size.
The chore
doc/build-unix.md:155tells every builder to fetchdb-4.8.30.NC.tar.gzfrom Oracle and compileit statically, because a distro BDB produces a wallet other builds cannot open. That single
dependency is the most fragile part of building (BOB), and it is a tax on every new build host and
every new contributor.
Why it does not need descriptor wallets
#41 proposes retiring it by adopting descriptor wallets on SQLite. That means porting HD wallets
(Core 0.15), descriptors (0.17 - 0.21), PSBT (0.17), the SQLite backend (0.23) and
migratewallet(0.24) into a tree that has none of the scaffolding: there is no
CHDChain, no descriptor code andno PSBT anywhere under
src/.The build dependency can go without any of that, by replacing the storage engine underneath
CWalletDBand keeping every existing record type exactly as it is. The surface is small:CWalletDBis the only subclass ofCDB.CDB::Read/Write/Erase/Existsalready serialize throughCDataStreamto byte blobs,so a table of key/value BLOBs is a direct substitution.
src/db.cppandsrc/db.hin three places only:Dbc*cursors at 3 sites inwalletdb.cpp,Dbtat 2 sites in its salvage path, and a version string printed byinit.cppand
qt/rpcconsole.cpp.src/db.cppis 454 lines andsrc/db.his 312.What is genuinely open
The same question #41 raises: an existing
wallet.datstill has to be read by something. So thedependency moves to a one-time converter rather than disappearing, and the decision is whether that
converter ships in the wallet, ships separately, or the old format is simply supported read-only for
a transition window.
Notes
and it is runnable today: it needs
db_dump, which a BDB built with its utilities provides. Itran twice as a release gate for v0.13.8.