loki icon indicating copy to clipboard operation
loki copied to clipboard

detectLevelFromLogLine does not cover all cases

Open sofielanduyts opened this issue 1 year ago • 3 comments

The func detectLevelFromLogLine is not fully complete. (loki/pkg/distibutor/distributor.go) For example, log lines with WARN .... will not be handled as level warning.

Removing the colon would include all cases.

This creates inconsistency with grafana as well. Image Even though there is no detected_level, it does get the color orange.

sofielanduyts avatar Oct 08 '24 15:10 sofielanduyts

Having a similar issue as well, where my level is called "cleared" that is probably not super standard either :)

I did mention it in #12645 as I am also wondering how to handle this in the "right" way

camrossi avatar Oct 08 '24 22:10 camrossi

Somehow all log lines with WARN handled as errors on my loki

jafnhaar avatar Oct 14 '24 05:10 jafnhaar

It will be nice if we can map them in loki config, since there is many variations. warning/WARN, error/ERR, there is also numerical severity in some apps.

rlex avatar Oct 14 '24 12:10 rlex