|
Motion Master 6.0.0-alpha.86
Next-generation motion control software
|
"logging.file" block — the rotating log file.
More...
#include <config.h>
Public Attributes | |
| bool | enabled = true |
| std::string | level = "debug" |
| std::string | directory |
| uint32_t | maxSizeMb = 10 |
| uint32_t | maxFiles = 5 |
| How many rotated files to keep beside the active one. | |
"logging.file" block — the rotating log file.
The console and the in-memory ring behind GET /api/log both die with the process, which leaves nothing to attach to a bug report after a crash or a restart — and on Windows, where the binary is commonly run from a console window rather than under a service manager, nothing captures stdout either. This is the copy that survives.
It lives under the user-cache root by default, which is what makes it reachable: everything under that root is listed by GET /api/user-cache, so the file can be downloaded from the Console's Storage page rather than found on disk over someone's shoulder.
| std::string FileLoggingConfig::directory |
"" = a "logs" subdirectory of the user-cache root (so setting userCache.directory moves the log with it, and it stays under /api/user-cache). Set to write elsewhere — a path outside that root is not served by the API, so the file must then be fetched from the host.
| bool FileLoggingConfig::enabled = true |
Write the log to a file at all. Disable for a read-only or air-gapped install; the console and GET /api/log are unaffected.
| std::string FileLoggingConfig::level = "debug" |
Verbosity of the file, independent of LoggingConfig::level so the console can stay readable while the file keeps the detail a support request needs. Defaults to debug for that reason. The logger itself runs at whichever of the two is more verbose, so this cannot be starved by the console setting.
| uint32_t FileLoggingConfig::maxFiles = 5 |
How many rotated files to keep beside the active one.
| uint32_t FileLoggingConfig::maxSizeMb = 10 |
Rotate once the active file reaches this size. Total disk use is bounded by maxSizeMb × (maxFiles + 1) — the active file plus its rotated siblings.