This release introduces asynchronous metrics, broadens codec coverage, and adds API and reliability improvements across backend lifecycle handling, sinks, and platform-specific paths.
Quill can now offload both logs and metric samples through the same backend worker, with metric metadata registered up front and each publish call enqueueing only a compact, fixed-size sample record on the hot path.
- Added asynchronous metrics support, including metric registration APIs,
Logger::publish_metric(), theMETRIC(...)macro, and backend sink delivery throughSink::write_metric(). - Added an optional
PrometheusSinkand examples for both a custom metric sink and Prometheus-backed export: custom metric sink example, Prometheus sink example - Added per-thread mapped diagnostic context (MDC) support with
Logger::set_mdc(),Logger::erase_mdc(),Logger::clear_mdc(), the%(mdc)pattern attribute, andBackendOptions::mdc_format_patternfor global MDC rendering. - Added std codec support for
std::variant,std::bitset,std::complex, andstd::error_code. - Extended
quill/std/Chrono.hcodec support to match bundled fmt's C++20 calendar formatters, includingstd::chrono::year,month,day,weekday, andyear_month_daywhen available. - Added C++20 module support groundwork, including export markers and macro cleanup.
- Switched to native file handles (
CreateFile/WriteFile) on Windows for improved write throughput compared toFILE*. - Added strict
Frontend::create_sink()andFrontend::create_logger()APIs for callers that want duplicate names to fail instead of reusing existing objects. - Added
CsvWriter::close()for deterministic logger removal and file closure before backend shutdown. - Added
BackendOptions::ensure_monotonic_output_timestampsto correct regular log and metric output timestamps that would otherwise move backwards. Backtrace records keep their original capture timestamps. BackendOptions::cpu_affinitynow supports pinning the backend to multiple CPUs.- Added a fallback to
fs::absolutewhenfs::canonicalfails on RAM disks. (#910) - Hardened backend, signal-handler, manual-backend, and teardown paths with more robust startup and shutdown behavior.
- Fixed multiple codec, sink rotation, named-argument, queue, and platform-specific edge cases.
- Fixed an infinite loop in the backend when the user-provided
error_notifierthrows. (#915) - Generated a Doxygen tag file for downstream documentation linking. (#914)
- Fix rotating sink reopen failure when the disk is full (#919)
- Fixes DLL unload on Windows, drain remaining log messages in stop() when backend thread was terminated externally (#925)
- Fixed stale named arguments from a pooled
TransitEvent. Thenamed_argspointer is now consistentlynullptrfor log statements without named arguments instead of occasionally being an empty vector (#926) StopWatchnow samples its elapsed time on the frontend at the log call site instead of when the backend formats the message, so logged values no longer include backend latency.RotatingFileSinkin append mode now counts rotated files left behind by previous runs towardsmax_backup_filesfor allRotationNamingSchemevalues, removing the oldest files on startup when they exceed the limit instead of letting them accumulate across restarts. Previously only theIndexscheme (and theDatescheme for same-day files) recovered existing files, soDateandDateAndTimefiles from earlier runs were never cleaned up. Recovered append-mode files are not removed whenoverwrite_rolled_filesis set tofalse. (#930)