loggingconventions

When to use the different log levels


There are different ways to log messages, in order of fatality:

  1. FATAL

  2. ERROR

  3. WARN

  4. INFO

  5. DEBUG

  6. TRACE

How do I decide when to use which?

What's a good heuristic to use?


Solution

  • I generally subscribe to the following convention: