MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / StartHTTPServer

Function StartHTTPServer

src/httpserver.cpp:430–442  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

428static std::vector<std::thread> g_thread_http_workers;
429
430void StartHTTPServer()
431{
432 LogPrint(BCLog::HTTP, "Starting HTTP server\n");
433 int rpcThreads = std::max((long)gArgs.GetArg("-rpcthreads", DEFAULT_HTTP_THREADS), 1L);
434 LogPrintf("HTTP: starting %d worker threads\n", rpcThreads);
435 std::packaged_task<bool(event_base*)> task(ThreadHTTP);
436 threadResult = task.get_future();
437 threadHTTP = std::thread(std::move(task), eventBase);
438
439 for (int i = 0; i < rpcThreads; i++) {
440 g_thread_http_workers.emplace_back(HTTPWorkQueueRun, workQueue);
441 }
442}
443
444void InterruptHTTPServer()
445{

Callers 1

AppInitServersFunction · 0.85

Calls 2

maxFunction · 0.85
GetArgMethod · 0.45

Tested by

no test coverage detected