Skip to content

Better description of different levels#18

Merged
erickhun merged 6 commits intomasterfrom
task/level-readme
Mar 3, 2020
Merged

Better description of different levels#18
erickhun merged 6 commits intomasterfrom
task/level-readme

Conversation

@erickhun
Copy link
Copy Markdown
Collaborator

@erickhun erickhun commented Mar 3, 2020

following @colinscape comment. This PR is inspired from the Monolog comments and give better description of the different logs level to use.

I've tried to add different examples based on some use case i've seen when integrating BuffLog to some of our services.

Levels Use case Examples
DEBUG Information used for interactive investigation, with no long-term value. Printing function names, steps inside a function.
INFO Interesting events. Track the general flow of the application. User logs in, SQL logs, worker process/delete a message...
NOTICE Uncommon events. This is the default verbosity level. Missing environment variables, page redirection, pod starting/restarting/terminating, retrying to query an API...
WARNING Exceptional occurrences that are not errors. Undesirable things that are not necessarily wrong. Use of deprecated APIs, poor use of an API, unauthorized access, pod restart because of memory limit ...
ERROR Runtime errors. Highlight when the current flow of execution is stopped due to a failure. Exceptions messages, incorect credentials or permissions...
CRITICAL Critical conditions. Describe an unrecoverable application, system crash, or a catastrophic failure that requires immediate attention. Application component unavailable, unexpected exception. entire website down, database unavailable ...

@colinscape @esclapes Would that be enough for engineers to know which level to use?

@erickhun erickhun requested review from colinscape and esclapes March 3, 2020 09:16
Copy link
Copy Markdown

@esclapes esclapes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems both clear and useful to me @erickhun 🌮 👍

Copy link
Copy Markdown

@colinscape colinscape left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great to me - definitely gives a lot more clarity on what is what! 🌟

@erickhun erickhun merged commit b0b1c31 into master Mar 3, 2020
@erickhun erickhun deleted the task/level-readme branch March 3, 2020 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants