Force log level at exec time
|As a||CEP developer|
|I would like to||change the log level and parameters at run time|
|So that||I don't have to re-compile my executable eveytime I need to check something or diagnose a problem|
Description / Overview
Choose one of (or both) solution:
enable the possibility to force the log parameter using environment variable, e.g.::ab:
CAMITK_LOG_LEVEL=WARNING CAMITK_LOG_TO_STDOUT=FALSE CAMITK_LOG_TO_FILE=TRUE CAMITK_LOG_FILE_DIRECTORY=/tmp camitk-imp"
camitk-imprunning with these log parameters instead of those defined in source or settings Caveat: you need to modify the environment variable and access to it from the code. Not really a problem, but can be tricky for people who don't understand it properly, modify their global environment (e.g. in ~/.bashrc) and then forgot they had define these things.
--debug=[options]argument from the command line execution for all CamiTK application with different options:
log level: le (error) lw (warning) li (info) lt (trace) d (display debug) s (display time stamp) log message: me mw mi mt p
- Use Qt to read the environment variables and modify the application properties accordingly
- Add a flag to
- there are more tests of the testlogger class that shows it work
Log Systemdocument is updated accordingly