class

LogRingBuffer

Ring buffer retained for post-crash log recovery. Producers are every thread in the process, so the slot write and the index advance have to be one atomic step — a mutex, not a pair of atomics.

Module
Logging
Header
#include "Logging/AsyncLogger.h"
Namespace
Mowo
Template
template<size_t Capacity>

Constructors

SignatureNameDescription
LogRingBuffer() = defaultLogRingBuffer

Public functions

ReturnsNameDescription
boolPush
boolPop
std::vector<LogMessage>GetAllBest-effort snapshot.
voidClear
boolIsEmpty
size_tSize

Function details

LogRingBuffer

C++
LogRingBuffer() = default

Push

C++
bool Push(const LogMessage& msg)

Pop

C++
bool Pop(LogMessage& msg)

GetAll

C++
std::vector<LogMessage> GetAll() const

Best-effort snapshot. The crash handler runs on the faulting thread, which may itself hold m_mutex, so a failed lock reads on anyway rather than deadlocking and losing the dump entirely.

Clear

C++
void Clear()

IsEmpty

C++
bool IsEmpty() const

Size

C++
size_t Size() const
Generated from Logging/AsyncLogger.h via logging.json · Oct 27, 2026Version 1.0.0