hrxi / tracing-loki

A tracing layer for shipping logs to Grafana Loki
Apache License 2.0
43 stars 20 forks source link

strip ansi codes from messages #25

Closed marcmenem closed 9 months ago

marcmenem commented 10 months ago

not really an issue, more a question.

My logs contain a lot of ansi esc codes to have a colorful stdout outpout. This is hard to read in Grafana. I would like to strip the ansi codes from messages before shipping them to loki. How should I proceed?

marcmenem commented 9 months ago

FWIW, Grafana has some features to decolorize logs, and can use ansi codes in some cases, so it is better to do processing in the Grafana dashboards themselves