mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-06-03 16:02:34 +02:00
add node interface method for getting maximum mempool size
Github-Pull: gui#825
Rebased-From: bbde6ffefe
This commit is contained in:
parent
55bd5d8015
commit
2197b33617
@ -162,6 +162,9 @@ public:
|
||||
//! Get mempool dynamic usage.
|
||||
virtual size_t getMempoolDynamicUsage() = 0;
|
||||
|
||||
//! Get mempool maximum memory usage.
|
||||
virtual size_t getMempoolMaxUsage() = 0;
|
||||
|
||||
//! Get header tip height and time.
|
||||
virtual bool getHeaderTip(int& height, int64_t& block_time) = 0;
|
||||
|
||||
|
@ -269,6 +269,7 @@ public:
|
||||
int64_t getTotalBytesSent() override { return m_context->connman ? m_context->connman->GetTotalBytesSent() : 0; }
|
||||
size_t getMempoolSize() override { return m_context->mempool ? m_context->mempool->size() : 0; }
|
||||
size_t getMempoolDynamicUsage() override { return m_context->mempool ? m_context->mempool->DynamicMemoryUsage() : 0; }
|
||||
size_t getMempoolMaxUsage() override { return m_context->mempool ? m_context->mempool->m_max_size_bytes : 0; }
|
||||
bool getHeaderTip(int& height, int64_t& block_time) override
|
||||
{
|
||||
LOCK(::cs_main);
|
||||
|
Loading…
Reference in New Issue
Block a user