3 ms·
> No! Log it and still retry. You will likely say this is a form of logging, and you’re right, but I think this is a better fit for a metric rather than a log.
by Spivak 7y ago
> No! Log it and still retry.
You will likely say this is a form of logging, and you’re right, but I think this is a better fit for a metric rather than a log.
“Something something retried at…” isn’t nearly as useful as the “the number of retries peaked at…”
- perlgeek 7y agoBoth logging and metrics can be useful in such a case. Metrics are useful to get a general picture, and logging is useful when you try to find out in one specific instance what happened. If you have a billion requests per day, you likely don't want logging for retries; if you have a small number of requests, many of them important enough to investigate individual errors, you absolutely want logs on what happened to each request.