Skip to content

Commit

Permalink
merge bitcoin#24537: Split mempool RPCs from blockchain.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
kwvg committed Dec 20, 2024
1 parent 537d3b3 commit dfa4772
Show file tree
Hide file tree
Showing 8 changed files with 513 additions and 468 deletions.
2 changes: 2 additions & 0 deletions src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,7 @@ BITCOIN_CORE_H = \
rpc/blockchain.h \
rpc/client.h \
rpc/index_util.h \
rpc/mempool.h \
rpc/mining.h \
rpc/protocol.h \
rpc/rawtransaction_util.h \
Expand Down Expand Up @@ -530,6 +531,7 @@ libbitcoin_server_a_SOURCES = \
rpc/evo.cpp \
rpc/index_util.cpp \
rpc/masternode.cpp \
rpc/mempool.cpp \
rpc/governance.cpp \
rpc/mining.cpp \
rpc/misc.cpp \
Expand Down
2 changes: 1 addition & 1 deletion src/bench/rpc_mempool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// file COPYING or http://www.opensource.org/licenses/mit-license.php.

#include <bench/bench.h>
#include <rpc/blockchain.h>
#include <rpc/mempool.h>
#include <txmempool.h>

#include <univalue.h>
Expand Down
1 change: 1 addition & 0 deletions src/rest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include <primitives/block.h>
#include <primitives/transaction.h>
#include <rpc/blockchain.h>
#include <rpc/mempool.h>
#include <rpc/protocol.h>
#include <rpc/server.h>
#include <rpc/server_util.h>
Expand Down
463 changes: 3 additions & 460 deletions src/rpc/blockchain.cpp

Large diffs are not rendered by default.

7 changes: 0 additions & 7 deletions src/rpc/blockchain.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ extern RecursiveMutex cs_main;
class CBlock;
class CBlockIndex;
class CChainState;
class CTxMemPool;
class UniValue;
struct NodeContext;
namespace llmq {
Expand All @@ -43,12 +42,6 @@ void RPCNotifyBlockChange(const CBlockIndex*);
/** Block description to JSON */
UniValue blockToJSON(BlockManager& blockman, const CBlock& block, const CBlockIndex* tip, const CBlockIndex* blockindex, const llmq::CChainLocksHandler& clhandler, const llmq::CInstantSendManager& isman, bool txDetails = false) LOCKS_EXCLUDED(cs_main);

/** Mempool information to JSON */
UniValue MempoolInfoToJSON(const CTxMemPool& pool, const llmq::CInstantSendManager& isman);

/** Mempool to JSON */
UniValue MempoolToJSON(const CTxMemPool& pool, const llmq::CInstantSendManager* isman, bool verbose = false, bool include_mempool_sequence = false);

/** Block header to JSON */
UniValue blockheaderToJSON(const CBlockIndex* tip, const CBlockIndex* blockindex, const llmq::CChainLocksHandler& clhandler) LOCKS_EXCLUDED(cs_main);

Expand Down
Loading

0 comments on commit dfa4772

Please sign in to comment.