0
0
Fork 0
mirror of https://github.com/bitcoin/bitcoin.git synced 2025-03-08 14:34:53 -05:00
bitcoin-core/src/kernel
Ava Chow c07935bcf5
Merge bitcoin/bitcoin#28960: kernel: Remove dependency on CScheduler
d5228efb53 kernel: Remove dependency on CScheduler (TheCharlatan)
06069b3913 scripted-diff: Rename MainSignals to ValidationSignals (TheCharlatan)
0d6d2b650d scripted-diff: Rename SingleThreadedSchedulerClient to SerialTaskRunner (TheCharlatan)
4abde2c4e3 [refactor] Make MainSignals RAII styled (TheCharlatan)
84f5c135b8 refactor: De-globalize g_signals (TheCharlatan)
473dd4b97a [refactor] Prepare for g_signals de-globalization (TheCharlatan)
3fba3d5dee [refactor] Make signals optional in mempool and chainman (TheCharlatan)

Pull request description:

  By defining a virtual interface class for the scheduler client, users of the kernel can now define their own event consuming infrastructure, without having to spawn threads or rely on the scheduler design.

  Removing `CScheduler` also allows removing the thread and exception modules from the kernel library.

  To make the `CMainSignals` class easier to use from a kernel library perspective, remove its global instantiation and adopt RAII practices.

  Renames `CMainSignals` to `ValidationSignals`, which more accurately describes its purpose and scope.

  Also make the `ValidationSignals` in the `ChainstateManager` and CTxMemPool` optional. This could be useful in the future for using or testing these classes without having to instantiate any form of signal handling.

  ---

  This PR is part of the [libbitcoinkernel project](https://github.com/bitcoin/bitcoin/issues/27587). It improves the kernel API and removes two modules from the kernel library.

ACKs for top commit:
  maflcko:
    re-ACK d5228efb53 🌄
  ryanofsky:
    Code review ACK d5228efb53. Just comment change since last review.
  vasild:
    ACK d5228efb53
  furszy:
    diff ACK d5228ef

Tree-SHA512: e93a5f10eb6182effb84bb981859a7ce750e466efd8171045d8d9e7fe46e4065631d9f6f533c5967c4d34c9bb7d7a67e9f4593bd4c5b30cd7b3bbad7be7b331b
2024-03-08 20:58:04 -05:00
..
bitcoinkernel.cpp
blockmanager_opts.h refactor: Move stopafterblockimport handling out of blockstorage 2023-07-11 12:00:57 +02:00
chain.cpp validation: add ChainstateRole 2023-09-30 06:38:47 -04:00
chain.h validation: add ChainstateRole 2023-09-30 06:38:47 -04:00
chainparams.cpp kernel: chainparams updates for 27.x 2024-03-04 10:56:27 +00:00
chainparams.h chainparams: add blockhash to AssumeutxoData 2023-09-30 06:38:47 -04:00
chainstatemanager_opts.h scripted-diff: Rename MainSignals to ValidationSignals 2024-02-15 14:45:51 +01:00
checks.cpp refactor: Replace std::optional<bilingual_str> with util::Result 2023-05-24 08:55:47 -04:00
checks.h fix includes for touched header files (iwyu) 2023-05-29 13:26:31 +02:00
coinstats.cpp Use Txid in COutpoint 2023-11-21 13:15:44 +00:00
coinstats.h coinstats: Fix hash_serialized2 calculation 2023-10-20 22:53:05 +02:00
context.cpp Get rid of shutdown.cpp/shutdown.h, use SignalInterrupt directly 2023-12-04 15:39:15 -04:00
context.h Get rid of shutdown.cpp/shutdown.h, use SignalInterrupt directly 2023-12-04 15:39:15 -04:00
cs_main.cpp kernel: add missing include 2023-02-22 15:46:21 +00:00
cs_main.h refactor: add kernel/cs_main.* 2023-01-05 09:05:14 +00:00
disconnected_transactions.cpp bugfix: correct DisconnectedBlockTransactions memory usage 2023-10-19 16:14:36 +01:00
disconnected_transactions.h bugfix: correct DisconnectedBlockTransactions memory usage 2023-10-19 16:14:36 +01:00
mempool_entry.h tx fees: update m_from_disconnected_block to m_mempool_limit_bypassed 2024-01-02 12:41:01 +01:00
mempool_limits.h refactor: mempool: add MemPoolLimits::NoLimits() 2022-10-05 13:07:11 +01:00
mempool_options.h scripted-diff: Rename MainSignals to ValidationSignals 2024-02-15 14:45:51 +01:00
mempool_persist.cpp Don't use scientific notation in log messages 2024-01-31 21:20:05 +02:00
mempool_persist.h Add importmempool RPC 2023-08-07 11:33:34 +02:00
mempool_removal_reason.cpp move-only: Create src/kernel/mempool_removal_reason.h 2023-08-17 16:26:20 +02:00
mempool_removal_reason.h move-only: Create src/kernel/mempool_removal_reason.h 2023-08-17 16:26:20 +02:00
messagestartchars.h kernel: Move MessageStartChars to its own file 2023-09-12 22:51:38 +02:00
notifications_interface.h kernel: Remove StartShutdown calls from validation code 2023-07-11 12:30:56 -04:00
validation_cache_sizes.h validationcaches: Use size_t for sizes 2022-08-03 12:03:28 -04:00