日志输出要有洁癖

原文https://blog.codinghorror.com/the-problem-with-logging/

不要随意的打日志,抵制日志越多越好

  1. Logging means more code.
  2. Logging isn't free
  3. If it's worth saving to a logfile, it's worth showing in the user interface.
  4. The more you log, the less you can find.
  5. The logfile that cried Wolf.

总结

Resist the tendency to log everything.