import type { IGetServerSummariesUseCase, ServerSummariesResult } from '../ports/inbound/IGetServerSummariesUseCase.js'; import type { IServerRepository } from '../ports/outbound/IServerRepository.js'; import type { IContainerRuntimePort } from '../ports/outbound/IContainerRuntimePort.js'; import type { IServerConsolePort } from '../ports/outbound/IServerConsolePort.js'; import type { ServerInfo } from '../../types/index.js'; export interface GetServerSummariesOptions { /** Per-server wait for RCON `list`. Default 2000 ms. */ timeoutMs?: number; /** * Per-server wait for container stats. Default 3000 ms: `docker stats * --no-stream` samples twice, so it often needs more than the RCON timeout. */ statsTimeoutMs?: number; /** How long the players and stats of a running server are reused. Default 10000 ms. */ ttlMs?: number; /** Clock for the TTL, in ms. Default Date.now. */ now?: () => number; } /** * Server list summary (#764). * * Adds config.env fields (`IServerRepository.getConfig`) to every server, and * players (`IServerConsolePort.listPlayers`) and memory stats * (`IContainerRuntimePort.getStatsAsync`) to running servers. The probes of all * running servers run in parallel, each under its own timeout, so one hung * server costs at most the timeout and affects only itself. * * Probes are cached per server for `ttlMs` (failures too, so a hung server is * not hit on every poll) and shared by concurrent calls. A server seen not * running loses its cache entry. config.env is read on every call. Keep one * instance per process for the cache to apply. */ export declare class GetServerSummariesUseCase implements IGetServerSummariesUseCase { private readonly serverRepository; private readonly runtime; private readonly console; private readonly timeoutMs; private readonly statsTimeoutMs; private readonly ttlMs; private readonly now; private readonly cache; constructor(serverRepository: Pick, runtime: Pick, console: Pick, options?: GetServerSummariesOptions); execute(servers: ServerInfo[]): Promise; private summarize; private readConfig; private probe; /** Never rejects. */ private runProbe; } //# sourceMappingURL=GetServerSummariesUseCase.d.ts.map