elements/src/kernel
glozow 821f5c824f
Merge bitcoin/bitcoin#25487: [kernel 3b/n] Decouple {Dump,Load}Mempool from ArgsManager
cb3e9a1e3f Move {Load,Dump}Mempool to kernel namespace (Carl Dong)
aa30676541 Move DEFAULT_PERSIST_MEMPOOL out of libbitcoinkernel (Carl Dong)
06b88ffb8a LoadMempool: Pass in load_path, stop using gArgs (Carl Dong)
b857ac60d9 test/fuzz: Invoke LoadMempool via CChainState (Carl Dong)
b3267258b0 Move FopenFn to fsbridge namespace (Carl Dong)
ae1e8e3756 mempool: Use NodeClock+friends for LoadMempool (Carl Dong)
f9e8e5719f mempool: Improve comments for [GS]etLoadTried (Carl Dong)
813962da0b scripted-diff: Rename m_is_loaded -> m_load_tried (Carl Dong)
413f4bb52b DumpMempool: Pass in dump_path, stop using gArgs (Carl Dong)
bd4407817e DumpMempool: Use std::chrono instead of weird int64_t arthmetics (Carl Dong)
c84390b741 test/mempool_persist: Test manual savemempool when -persistmempool=0 (Carl Dong)

Pull request description:

  This is part of the `libbitcoinkernel` project: #24303, https://github.com/bitcoin/bitcoin/projects/18

  -----

  This PR moves `{Dump,Load}Mempool` into its own `kernel/mempool_persist` module and introduces `ArgsManager` `node::` helpers in `node/mempool_persist_args`to remove the scattered calls to `GetBoolArg("-persistmempool", DEFAULT_PERSIST_MEMPOOL)`.

  More context can be gleaned from the commit messages.

  -----

  One thing I was reflecting on as I wrote this was that in the long run, I think we should probably invert the validation <-> mempool relationship. Instead of mempool not depending on validation, it might make more sense to have validation not depend on mempool. Not super urgent since `libbitcoinkernel` will include both validation and mempool, but perhaps something for the future.

ACKs for top commit:
  glozow:
    re ACK cb3e9a1e3f via `git range-diff 7ae032e...cb3e9a1`
  MarcoFalke:
    ACK cb3e9a1e3f 🔒
  ryanofsky:
    Code review ACK cb3e9a1e3f

Tree-SHA512: 979d7237c3abb5a1dd9b5ad3dbf3b954f906a6d8320ed7b923557f41a4472deccae3e8a6bca0018c8e7a3c4a93afecc502acd1e26756f2054f157f1c0edd939d
2022-07-18 16:09:27 +01:00
..
bitcoinkernel.cpp b-cs: Define G_TRANSLATION_FUN in bitcoinkernel.cpp 2022-04-26 16:30:53 -04:00
chainstatemanager_opts.h Move ChainstateManagerOpts into kernel:: namespace 2022-07-14 08:27:54 -04:00
checks.cpp kernel: SanityChecks: Return an error struct 2022-06-02 12:22:46 -04:00
checks.h kernel: SanityChecks: Return an error struct 2022-06-02 12:22:46 -04:00
coinstats.cpp scripted-diff: Move src/kernel/coinstats to kernel:: 2022-05-23 14:53:35 -04:00
coinstats.h scripted-diff: Move src/kernel/coinstats to kernel:: 2022-05-23 14:53:35 -04:00
context.cpp init: Initialize globals with kernel::Context's life 2022-06-02 11:40:03 -04:00
context.h doc: fix typo in kernel/context.h 2022-06-08 10:03:43 -03:00
mempool_limits.h mempool: Use m_limit for UpdateTransactionsFromBlock 2022-06-28 15:49:15 -04:00
mempool_options.h Introduce mempoolfullrbf node setting. 2022-07-06 20:57:29 -04:00
mempool_persist.cpp Move {Load,Dump}Mempool to kernel namespace 2022-07-15 12:26:20 -04:00
mempool_persist.h Move {Load,Dump}Mempool to kernel namespace 2022-07-15 12:26:20 -04:00