2 ms·
The primary reason is that it's useful to know what was happening on a system when something was logged. When troubleshooting an unexpected error in a log, the
by marcc 9y ago
The primary reason is that it's useful to know what was happening on a system when something was logged. When troubleshooting an unexpected error in a log, the troubleshooting starts by building context. What was the action, what was the environment, etc. It's often rather difficult to diagnose an error message by simply looking at a log file.
For example, if your API server talked to Postgres and you start to see some timeouts, it's great to open a monitoring view for the same time period and see the overall traffic, the number of connections to postgres and what else was happening during this time.