pinojs/pino

Docs: Pino Logging with Grafana Promtail/Loki

Closed this issue · 3 comments

I recently spent way to much time to get Promtail and Loki to consume our pino logs in a way that I found satisfactory.
Since logs, which aren't processed or read by anything are basically useless, this should be fairly common challenge.

Information about setting this up properly is surprisingly hard to find, which is why, when I finally made it work, I decided to write an article about it.

I humbly present it here, A for feedback and B so it might be helpful to other pino users.
https://medium.com/@janpaepke/structured-logging-in-the-grafana-monitoring-stack-8aff0a5af2f5

If the maintainers agree this may be useful information, we could also consider linking it in the package docs somewhere.

Would you like to add a link to that page in our help section?

I've used pino-loki with great satisfaction as well.

pino-loki is really well made but as explained in the article it follows a different paradigm.

In our setup a service should not be concerned with log consumption, much less be tied to a loki instance/config.
In short: Logs should be pull, rather than push.

Regarding the link, I'd be happy to add a PR. Wanted to make sure it's useful first. 🙂

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.