Also report work queue threads in rpcinfo

This commit is contained in:
Duke Leto
2021-08-09 11:51:25 -04:00
parent 89a4226965
commit 63e1ede162
3 changed files with 14 additions and 0 deletions

View File

@@ -162,6 +162,11 @@ public:
boost::unique_lock<boost::mutex> lock(cs);
return maxDepth;
}
int NumThreads()
{
boost::unique_lock<boost::mutex> lock(cs);
return numThreads;
}
};
struct HTTPPathHandler
@@ -196,11 +201,17 @@ int getWorkQueueDepth()
{
return workQueue->Depth();
}
int getWorkQueueMaxDepth()
{
return workQueue->MaxDepth();
}
int getWorkQueueNumThreads()
{
return workQueue->NumThreads();
}
/** Check if a network address is allowed to access the HTTP server */
static bool ClientAllowed(const CNetAddr& netaddr)
{