
I think John's approach to having multiple log "levels" is to just use a separate log for each one (e.g. you might have logs called trace, debug, warning, info, and fatal). Logs are either enabled or disabled; there is no "level" or above-some-threshold-type checking as with some other common implementations.
Unfortunately, you lose relativity in logs, which is very important in diagnosing failures. Suppose a problem occurs that gets logged to the "fatal" log. Really, to find out all surrounding context, you need to merge all logs. Unless there is a common sequence number or something like that, you have no way of really knowing what sequence of events led to the problem since they are scattered about in a number of logs. You can make good guesses, but in large that handle multiple requests at the same time, it becomes very difficult.
From my experience (and I wrote several logging solutions used in
I am sorry to jump into the middle of discussion, but I wanted to comment on that: production) logging system is required to provide an explicit log level support. Any other solution is simply unacceptable. The same applies to keyword and category.
Note that the presence of multiple logs does *not* imply multiple files. You can use a single appender for everything:
add_appender ("*", write_to_file ("app.all.txt"));
Now you have multiple agents writing into the same file. It not only adding extra headache with synchronization. Most probably disable any buffering and still inconvenient to use.
I'd prefer a common log, which records levels.
Second that. Gennadiy