FrozenLab logoFrozenLab/ docs

VetroLog Configuration

Log level definitions, environment-aware formatters, and sensitive data redaction.

VetroLog Configuration

VetroLog supports environment-aware configuration to adapt between local interactive debugging and production ingestion sinks.

Log Levels

The logging engine adheres to standard severity tiers:

SeverityMethodTypical Application
tracelogger.trace(...)Verbose diagnostic traces and internal stepping.
debuglogger.debug(...)Development details, cache hits, database queries.
infologger.info(...)Standard operational events and lifecycle transitions.
warnlogger.warn(...)Non-fatal anomalies and recoverable conditions.
errorlogger.error(...)Failures requiring operational attention.
fatallogger.fatal(...)Unrecoverable crashes precipitating process exit.

Formatting Options

Formatters define how structured events are serialized before reaching output sinks:

// Sample configuration schema
export interface LoggerOptions {
  level?: 'trace' | 'debug' | 'info' | 'warn' | 'error' | 'fatal';
  format?: 'json' | 'pretty';
  redact?: string[];
  destination?: NodeJS.WritableStream;
}

Sensitive Data Redaction

Specify field paths that should be automatically sanitized before emission:

const logger = createLogger({
  redact: ['password', 'authorization', 'creditCard.number'],
});

[!NOTE] Maintainer Placeholder: Exact redaction glob syntax and custom serializer hooks are detailed in the GitHub issue tracker.