|
|
@ -1532,6 +1532,25 @@ UniValue getchaintxstats(const JSONRPCRequest& request) |
|
|
|
return ret; |
|
|
|
return ret; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
UniValue savemempool(const JSONRPCRequest& request) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
if (request.fHelp || request.params.size() != 0) { |
|
|
|
|
|
|
|
throw std::runtime_error( |
|
|
|
|
|
|
|
"savemempool\n" |
|
|
|
|
|
|
|
"\nDumps the mempool to disk.\n" |
|
|
|
|
|
|
|
"\nExamples:\n" |
|
|
|
|
|
|
|
+ HelpExampleCli("savemempool", "") |
|
|
|
|
|
|
|
+ HelpExampleRpc("savemempool", "") |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (!DumpMempool()) { |
|
|
|
|
|
|
|
throw JSONRPCError(RPC_MISC_ERROR, "Unable to dump mempool to disk"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return NullUniValue; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
static const CRPCCommand commands[] = |
|
|
|
static const CRPCCommand commands[] = |
|
|
|
{ // category name actor (function) argNames
|
|
|
|
{ // category name actor (function) argNames
|
|
|
|
// --------------------- ------------------------ ----------------------- ----------
|
|
|
|
// --------------------- ------------------------ ----------------------- ----------
|
|
|
@ -1552,6 +1571,7 @@ static const CRPCCommand commands[] = |
|
|
|
{ "blockchain", "gettxout", &gettxout, {"txid","n","include_mempool"} }, |
|
|
|
{ "blockchain", "gettxout", &gettxout, {"txid","n","include_mempool"} }, |
|
|
|
{ "blockchain", "gettxoutsetinfo", &gettxoutsetinfo, {} }, |
|
|
|
{ "blockchain", "gettxoutsetinfo", &gettxoutsetinfo, {} }, |
|
|
|
{ "blockchain", "pruneblockchain", &pruneblockchain, {"height"} }, |
|
|
|
{ "blockchain", "pruneblockchain", &pruneblockchain, {"height"} }, |
|
|
|
|
|
|
|
{ "blockchain", "savemempool", &savemempool, {} }, |
|
|
|
{ "blockchain", "verifychain", &verifychain, {"checklevel","nblocks"} }, |
|
|
|
{ "blockchain", "verifychain", &verifychain, {"checklevel","nblocks"} }, |
|
|
|
|
|
|
|
|
|
|
|
{ "blockchain", "preciousblock", &preciousblock, {"blockhash"} }, |
|
|
|
{ "blockchain", "preciousblock", &preciousblock, {"blockhash"} }, |
|
|
|