| 1264 | } |
| 1265 | |
| 1266 | void InterruptHTTPServer() |
| 1267 | { |
| 1268 | LogDebug(BCLog::HTTP, "Interrupting HTTP server"); |
| 1269 | if (g_http_server) { |
| 1270 | // Reject all new requests |
| 1271 | g_http_server->SetRequestHandler(RejectRequest); |
| 1272 | } |
| 1273 | |
| 1274 | // Interrupt pool after disabling requests |
| 1275 | g_threadpool_http.Interrupt(); |
| 1276 | } |
| 1277 | |
| 1278 | void StopHTTPServer() |
| 1279 | { |