diff options
| author | Stefan Boberg <[email protected]> | 2021-09-15 11:27:48 +0200 |
|---|---|---|
| committer | Stefan Boberg <[email protected]> | 2021-09-15 11:27:48 +0200 |
| commit | 2b9bed6635d95e15847c4d9b602e34d90e277d14 (patch) | |
| tree | 66fb191150ccbf9f56315a716abd23b25cc1d401 /zenstore/cidstore.cpp | |
| parent | xmake: added zenhttp dependency to make zen CLI tool buld (diff) | |
| download | zen-2b9bed6635d95e15847c4d9b602e34d90e277d14.tar.xz zen-2b9bed6635d95e15847c4d9b602e34d90e277d14.zip | |
Changed logging implementation
* Code should no longer directly `#include spdlog/spdlog.h`, instead use `#include <zencore/logging.h>`
* Instead of explicit calls to `spdlog::info(...)` and such please use the logging macros defined in `zencore/logging.h`. I.e `ZEN_INFO`, `ZEN_DEBUG`, `ZEN_TRACE`, `ZEN_ERROR`, `ZEN_CRITITCAL`
* The macros will pick up the "most local" logger via a `Log()` call to retrieve a logger instance. To override the default logger in a class please implement your own `Log()` function
Diffstat (limited to 'zenstore/cidstore.cpp')
| -rw-r--r-- | zenstore/cidstore.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/zenstore/cidstore.cpp b/zenstore/cidstore.cpp index 5a9ed9483..e6c7f98ee 100644 --- a/zenstore/cidstore.cpp +++ b/zenstore/cidstore.cpp @@ -4,9 +4,9 @@ #include <zencore/compress.h> #include <zencore/filesystem.h> +#include <zencore/logging.h> #include <zenstore/CAS.h> #include <zenstore/caslog.h> -#include <zencore/logging.h> #include <filesystem> @@ -86,7 +86,7 @@ struct CidStore::CidState m_LogFile.Replay([&](const IndexEntry& Ie) { m_CidMap.insert_or_assign(Ie.Uncompressed, Ie.Compressed); }); - spdlog::debug("CID index initialized: {} entries found", m_CidMap.size()); + ZEN_DEBUG("CID index initialized: {} entries found", m_CidMap.size()); } void Flush() { m_LogFile.Flush(); } |