Added some debug logs during scans, quite verbose

This commit is contained in:
emeric
2024-12-19 20:36:50 +01:00
parent 4c2be63e94
commit ac4baaac10
12 changed files with 39 additions and 0 deletions
@@ -21,6 +21,7 @@
#include <boost/asio/post.hpp>
#include "core/ILogger.hpp"
#include "core/ITraceLogger.hpp"
#include "scanners/IFileScanOperation.hpp"
@@ -52,6 +53,7 @@ namespace lms::scanner
{
{
LMS_SCOPED_TRACE_OVERVIEW("Scanner", operation->getName());
LMS_LOG(DBUPDATER, DEBUG, operation->getName() << ": scanning file '" << operation->getFile().string() << "'");
operation->scan();
}
@@ -57,6 +57,7 @@ namespace lms::scanner
{
[[maybe_unused]] auto [it, inserted]{ _scannerByExtension.emplace(extension, scanner) };
assert(inserted);
LMS_LOG(DBUPDATER, INFO, "Registered extension '" << extension.string() << "' for '" << scanner->getName() << "'");
}
}
@@ -139,6 +140,7 @@ namespace lms::scanner
if (_abortScan)
return;
LMS_LOG(DBUPDATER, DEBUG, scanOperation->getName() << ": processing result for '" << scanOperation->getFile().string() << "'");
scanOperation->processResult(context);
context.stats.scans++;
}