MCPcopy Create free account
hub / github.com/adcontextprotocol/adcp / checkHealth

Method checkHealth

server/src/health.ts:19–26  ·  view source on GitHub ↗
(agent: Agent)

Source from the content-addressed store, hash-verified

17 }
18
19 async checkHealth(agent: Agent): Promise<AgentHealth> {
20 const cached = this.healthCache.get(agent.url);
21 if (cached) return cached;
22
23 const health = await this.performHealthCheck(agent);
24 this.healthCache.set(agent.url, health);
25 return health;
26 }
27
28 private async performHealthCheck(agent: Agent): Promise<AgentHealth> {
29 const startTime = Date.now();

Callers 3

setupRoutesMethod · 0.80
prewarmCachesMethod · 0.80
refreshAgentSnapshotsMethod · 0.80

Calls 3

performHealthCheckMethod · 0.95
getMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected