aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/core_rpc_server.cpp
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2017-03-22 18:03:23 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2017-03-23 09:25:22 +0000
commit558cfc31caeb88398fe5bab9292246739586374d (patch)
tree4efe29371b0a9dd3d195d01ccff51a9d9b5b2a7b /src/rpc/core_rpc_server.cpp
parentcore: cache tx and block hashes in the respective classes (diff)
downloadmonero-558cfc31caeb88398fe5bab9292246739586374d.tar.xz
core, wallet: faster tx pool scanning
Includes a new RPC to get tx pool hashes fast.
Diffstat (limited to '')
-rw-r--r--src/rpc/core_rpc_server.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/rpc/core_rpc_server.cpp b/src/rpc/core_rpc_server.cpp
index 9f7e8aa38..a800dbb35 100644
--- a/src/rpc/core_rpc_server.cpp
+++ b/src/rpc/core_rpc_server.cpp
@@ -789,6 +789,14 @@ namespace cryptonote
return true;
}
//------------------------------------------------------------------------------------------------------------------------------
+ bool core_rpc_server::on_get_transaction_pool_hashes(const COMMAND_RPC_GET_TRANSACTION_POOL_HASHES::request& req, COMMAND_RPC_GET_TRANSACTION_POOL_HASHES::response& res)
+ {
+ CHECK_CORE_BUSY();
+ m_core.get_pool_transaction_hashes(res.tx_hashes);
+ res.status = CORE_RPC_STATUS_OK;
+ return true;
+ }
+ //------------------------------------------------------------------------------------------------------------------------------
bool core_rpc_server::on_stop_daemon(const COMMAND_RPC_STOP_DAEMON::request& req, COMMAND_RPC_STOP_DAEMON::response& res)
{
// FIXME: replace back to original m_p2p.send_stop_signal() after