Skip to content

log: Lower noisy messages to debug level

Simon McVittie requested to merge wip/smcv/calm-down-logging into main
  • log: Lower profiling messages to debug level unless SRT_LOG=timing

    There are two reasons we can get profiling messages: either because we explicitly enabled them with SRT_LOG=timing, or because we have asked to get all debug messages indiscriminately.

    If we're writing to the Journal, g_message() translates into LOG_NOTICE, which shows up with a distracting level of highlighting. This is appropriate if we specifically asked for timing information, but inappropriate if we just want general debug information, so reduce the log level in the latter case.

  • pv-adverb: Use g_debug in preference to g_message for environment, etc.

    As with commit e7fbf19e "pressure-vessel: Use g_debug for messages that only show when verbose" in pv-wrap, if opt_verbose is true, then we know we'll display these even if they are only at debug severity. Using g_debug instead of g_message gives them the correct prefixes in the log, and avoids a distracting level of highlighting in the systemd Journal.


This was annoying me. Ready for review, but not appropriate for inclusion in a hotfix, so I'm marking this as draft for now.

Merge request reports