From 0dd4e552ed70d224f28004cf3f2b5b02f0d5c912 Mon Sep 17 00:00:00 2001 From: gabi Date: Sun, 7 Dec 2014 04:27:46 +0200 Subject: [PATCH] async_logger comments --- include/spdlog/async_logger.h | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/include/spdlog/async_logger.h b/include/spdlog/async_logger.h index 7438d156..ff88a3cf 100644 --- a/include/spdlog/async_logger.h +++ b/include/spdlog/async_logger.h @@ -24,10 +24,13 @@ #pragma once -// Async logger +// Very fast asynchronous logger (millions of logs per second on aregular desktop) +// Uses pre allocated lockfree queue for maximum throughput even under large number of threads. // Upon each log write the logger: -// 1. Checks if its log level is enough to log the message -// 2. Push a new copy of the message to a queue (uses sinks::async_sink for this) +// 1. Checks if its log level is enough to log the message +// 2. Push a new copy of the message to a queue or block the caller until space is available +// 3. will throw spdlog_ex upon exceptions +// Upong destruction, logs all remaining messages in the queue before destructing.. #include #include "common.h"