mirror of https://github.com/Icinga/icinga2.git
ApiListener: drop unused thread pool
This commit is contained in:
parent
3a6caa2800
commit
64b2ac4b30
|
@ -109,22 +109,6 @@ void ApiListener::CopyCertificateFile(const String& oldCertPath, const String& n
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns the API thread pool.
|
|
||||||
*
|
|
||||||
* @returns The API thread pool.
|
|
||||||
*/
|
|
||||||
ThreadPool& ApiListener::GetTP()
|
|
||||||
{
|
|
||||||
static ThreadPool tp;
|
|
||||||
return tp;
|
|
||||||
}
|
|
||||||
|
|
||||||
void ApiListener::EnqueueAsyncCallback(const std::function<void ()>& callback, SchedulerPolicy policy)
|
|
||||||
{
|
|
||||||
GetTP().Post(callback, policy);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ApiListener::OnConfigLoaded()
|
void ApiListener::OnConfigLoaded()
|
||||||
{
|
{
|
||||||
if (m_Instance)
|
if (m_Instance)
|
||||||
|
|
|
@ -134,9 +134,6 @@ private:
|
||||||
void NewClientHandlerInternal(boost::asio::yield_context yc, const std::shared_ptr<AsioTlsStream>& client, const String& hostname, ConnectionRole role);
|
void NewClientHandlerInternal(boost::asio::yield_context yc, const std::shared_ptr<AsioTlsStream>& client, const String& hostname, ConnectionRole role);
|
||||||
void ListenerCoroutineProc(boost::asio::yield_context yc, const std::shared_ptr<boost::asio::ip::tcp::acceptor>& server, const std::shared_ptr<boost::asio::ssl::context>& sslContext);
|
void ListenerCoroutineProc(boost::asio::yield_context yc, const std::shared_ptr<boost::asio::ip::tcp::acceptor>& server, const std::shared_ptr<boost::asio::ssl::context>& sslContext);
|
||||||
|
|
||||||
static ThreadPool& GetTP();
|
|
||||||
static void EnqueueAsyncCallback(const std::function<void ()>& callback, SchedulerPolicy policy = DefaultScheduler);
|
|
||||||
|
|
||||||
WorkQueue m_RelayQueue;
|
WorkQueue m_RelayQueue;
|
||||||
WorkQueue m_SyncQueue{0, 4};
|
WorkQueue m_SyncQueue{0, 4};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue