According to the following code:
template <typename T, typename... Args>
void fatal(const std::string& fmt, T arg1, Args&&... args)
{
log(Poco::format(fmt, arg1, std::forward<Args>(args)...), Message::PRIO_FATAL);
}
The Format is always called for a logging line, and then the if condition to actually test if it should be "Logged" is done in the log function afterwards.
Would it not be more performant to only call the logging formatting iff the level is "Useable" ?
i.e. move the checking before the formatting