Refresh HiveGrid Cloud reference snapshot
This commit is contained in:
1 parent
5e99e14772
commit
7f88026f79
5955 files changed
+1177325
-188362
No files matched your search
@@ -0,0 +1,16 @@
|
||||
import type { Server } from "node:http";
|
||||
|
||||
export const MCP_HEADERS_TIMEOUT_MS = 10_000;
|
||||
export const MCP_REQUEST_TIMEOUT_MS = 30_000;
|
||||
export const MCP_KEEP_ALIVE_TIMEOUT_MS = 5_000;
|
||||
export const MCP_MAX_HEADERS = 100;
|
||||
export const MCP_MAX_REQUESTS_PER_SOCKET = 1_000;
|
||||
|
||||
export function hardenMcpHttpServer(server: Server): Server {
|
||||
server.headersTimeout = MCP_HEADERS_TIMEOUT_MS;
|
||||
server.requestTimeout = MCP_REQUEST_TIMEOUT_MS;
|
||||
server.keepAliveTimeout = MCP_KEEP_ALIVE_TIMEOUT_MS;
|
||||
server.maxHeadersCount = MCP_MAX_HEADERS;
|
||||
server.maxRequestsPerSocket = MCP_MAX_REQUESTS_PER_SOCKET;
|
||||
return server;
|
||||
}
|
||||
Reference in new issue
Block a user