LLDHub
Problems·Logger / Logging Framework
L2 · Easy

Logger / Logging Framework

Problem

Design a flexible logging framework that supports multiple log levels, formatters, and output destinations.

Requirements

  • Support log levels: DEBUG, INFO, WARNING, ERROR, CRITICAL
  • Multiple output destinations: Console, File, Database
  • Configurable log format (timestamp, level, message, context)
  • Filter logs by minimum level
  • Support multiple loggers with different configurations
  • Thread-safe logging

Constraints

  • Only one Logger instance per name (use registry)
  • Log entries below configured level should be discarded
✓ Saved