Skip to content

Commit dbcec32

Browse files
committed
Add request tracking to MCP server health endpoint
- Track health check requests as server activity - Increment request counter on health endpoint access
1 parent 43b2e17 commit dbcec32

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

packages/mcp-server/src/health-server.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ export function startHealthServer(port = 3128) {
1818
}
1919

2020
if (url.pathname === '/health' && req.method === 'GET') {
21+
// Count health check requests as activity
22+
totalRequests++;
23+
2124
const healthData = {
2225
status: 'healthy',
2326
timestamp: new Date().toISOString(),

0 commit comments

Comments
 (0)