Understanding logs, particularly the differences between its main levels, can make a difference in production environments.

🔍 INFO: This is your day-to-day. These logs provide general information about the functioning of your application.
They're the rhythm of your application's heartbeat, signifying all is well.

🔬 DEBUG: Here's your magnifying glass. Debug logs contain detailed information for problem diagnosis.
They're verbose and usually turned off in production, but immensely helpful during development and debugging.

⚠️ WARN: A yellow light.
Warning logs indicate that something unexpected happened, but the application still works as expected.
It's a sign that something might be wrong - go look closer.

🚨 ERROR: Red alert. Error logs signify that something failed.
An operation didn't complete, or an exception was thrown.
These need urgent attention as they affect the application's functioning.

You may reduce reliance on logging by strengthening your testing methodology. But when 💩happens, logs always save us.

💡 Don't implement them the wrong way:

- Logs are not noise.

- Logs are to be written by a logging abstraction.

- Your app has no idea how and where logs are written.

- Log levels are to be defined at the infrastructure level, using environment variables.

#softwarecraftsmanship