import * as winston from "winston"; /** * A named handle onto the process-wide logger. * * This used to build its own winston logger with four File transports per instance. It * no longer builds anything: there are ~43 of these across the codebase, and * `ServiceNowRequest` is constructed per HTTP call, so each request was opening four * more never-closed append streams. That is where the 120 MB of logs came from, and it * also made rotation impossible — File transports track size independently, so several * on one path interleave renames and lose lines. * * Destination, level, and rotation now live in LogConfig and are set once by the * application. See `configureLogging`. */ export declare class Logger { _labelName: string; /** Set only by `setLogger`. Overrides the shared root for this instance. */ private _override?; private _cached?; private _epochSeen; /** * @param labelName Appears as `label` on every record from this instance. * @param level Ignored. Kept so existing call sites still compile. * @deprecated Pass the level to `configureLogging` instead — it applies process-wide. */ constructor(labelName: string, level?: string); /** Replaces the underlying winston logger for this instance only. Test seam. */ setLogger(logger: winston.Logger): void; getLabel(): string; /** * @deprecated The `level` argument the constructor accepts is ignored; use * `configureLogging({level})`. */ static createLogger(labelName: string): Logger; /** Resolves the shared root, rebuilding the cached reference if config changed. */ private root; /** * Attaches this instance's label to the record. * * The label used to be a winston format bound to a per-instance logger. With one * shared root it has to travel with the call. Callers pass all sorts of things as * `metadata`, so a non-object is nested rather than spread — spreading a string * would scatter it across numeric keys. */ private meta; debug(message: string, metadata?: unknown): void; info(message: string, metadata?: unknown): void; error(message: string, metadata?: unknown): void; warn(message: string, metadata?: unknown): void; verbose(message: string, metadata?: unknown): void; http(message: string, metadata?: unknown): void; silly(message: string, metadata?: unknown): void; addInfoMessage(message: string, metadata?: unknown): void; addErrorMessage(message: string, metadata?: unknown): void; addWarnMessage(message: string, metadata?: unknown): void; successful(message: string, metadata?: unknown): void; }