HomePhabricator

[validation] Always call mempool.check() after processing a new transaction

Description

[validation] Always call mempool.check() after processing a new transaction

Summary:
CTxMemPool::check() will carry out internal consistency checks 1/n times,
where n is set by the -checkmempool configuration option. By default,
mempool consistency checks are disabled entirely on mainnet.

Therefore, this change has no effect on mainnet nodes running with
default configuration. It simply removes the responsibility to trigger
mempool consistency checks from net_processing.

This concludes a backport of core#23173
https://github.com/bitcoin/bitcoin/pull/23173/commits/0fdb619aaf1d62598263361a6082d182be1af792

Depends on D12235

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D12236

Details

Provenance
John Newbery <john@johnnewbery.com>Authored on Sep 27 2021, 17:11
PiRKCommitted on Oct 13 2022, 16:22
PiRKPushed on Oct 13 2022, 16:22
Reviewer
Restricted Project
Differential Revision
D12236: [validation] Always call mempool.check() after processing a new transaction
Parents
rABC924ee9eb564a: [validation] Add CChainStateManager::ProcessTransaction() and use it outsideā€¦
Branches
Unknown
Tags
Unknown