Hi, If i use the label for storing the message field, do you know what is the maximum length of the string that should not be exceeded? Is there a recommendation on the maximum size?
Thanks Loïc Le mercredi 22 juin 2022 à 16:44:37 UTC+2, Loïc a écrit : > Thanks for your reply Brian :) > > Le mercredi 22 juin 2022 à 15:24:19 UTC+2, Brian Candler a écrit : > >> > if i want sent the error log into the alarm generated, i should add the >> error message as label of my metric. >> >> That gives you a high cardinality label, which is not what Prometheus is >> designed for. Every distinct combination of labels defines a new >> timeseries. >> >> I can see two solutions here: >> >> 1. Use a log storage system like Loki or ElasticSearch/OpenSearch, rather >> than Prometheus >> >> 2. Include the error message as an "exemplar". When you have multiple >> events in the same timeseries and time window, then you'll only get one >> exemplar. But it may be good enough to give you an "example" of the type >> of error you're seeing, and it keeps the cardinality of your counters low. >> (Exemplars are experimental and need to be turned on with a feature flag, >> and I don't know if mtail supports them) >> >> -- You received this message because you are subscribed to the Google Groups "Prometheus Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/e71e6129-d7f2-40a7-ac60-72dc0c71aaf6n%40googlegroups.com.

