refactor!: Box the changeset of StoreErrorWithDump #1998
refactor!: Box the changeset of StoreErrorWithDump #1998evanlinjin merged 1 commit intobitcoindevkit:masterfrom
Box the changeset of StoreErrorWithDump #1998Conversation
|
I agree with the use of |
46606d0 to
56f1fad
Compare
|
Removed the |
There was a problem hiding this comment.
Looks good to me!
I wonder is it necessary to box the changeset when returned in the
Okvalue, for example indumpandload, etc.
We can ignore that, thinking in terms of the goal of this crate, which is to provide a testing database to experiment, not performance. load and dump are called most of the time just on the startup and on the shutdown of the code using the database, with occasional dumps for debugging.
|
ACK 56f1fad |
oleonardolima
left a comment
There was a problem hiding this comment.
ACK 56f1fad
You need to do a rebase to get the updated rustc and MSRV fixed CI.
As mentioned in the corresponding issue, `Box`ing helps reduce memory overhead while passing the enum around and also to limit the size of enums with `StoreErrorWithDump` as a variant. Breaking: The enum `StoreErrorWithDump` has been changed.
56f1fad to
418753f
Compare
Description
Fixes #1991. As the linked issue mentions
Boxing helps reduce memory overhead and limits the size of enums withStoreErrorWithDumpas variant.Breaking: The enum
StoreErrorWithDumpand the functionsload,dumpandload_or_createhave been changed.Changelog Notice
Checklists
All Submissions: