blowback-context
Version:
MCP server that integrates with FE development server for Cursor
32 lines (31 loc) • 921 B
TypeScript
/**
* Manages log files with rotation implementation
*/
export declare class LogManager {
private static instance;
private writeStream;
private currentLogCount;
private readonly MAX_LOGS_PER_FILE;
private readonly logDir;
private currentFileNumber;
private checkpointStreams;
private readonly MAX_CHECKPOINT_FILES;
private constructor();
static getInstance(): LogManager;
private getLogFilePath;
private initializeLogFile;
private attachCheckpointStream;
private isCheckpointStreamAttached;
/**
* detach checkpoint streams that are not in use
*/
private detachCheckpointStreams;
appendLog(logEntry: string, checkpointId?: string): Promise<void>;
readLogs(limit: number, checkpointId?: string): Promise<{
logs: string[];
writePosition: number;
totalLogs: number;
}>;
close(): void;
closeAll(): void;
}