Prometheus uses an inverted index to map names to series. I highly recommend watching this talk: https://promcon.io/2017-munich/talks/storing-16-bytes-at-scale/
On Mon, Jun 10, 2024 at 3:39 PM akshay sharma <[email protected]> wrote: > Hi All, > > I'm working on Prometheus performance optimization. And simultaneously, I > am also going through the prometheus documentation. > > I have a fair understanding of how Prometheus processes data/samples and > where it stores the data > > Although, I have a couple of questions in my mind for which I am seeking > answers. > > 1) Does Prometheus store the metric name every single time it fetches the > data? Or does it just store the value/timestamp and soft link/link to the > metric name? > ex: testing_prometheus_performace{"label1": "Value1", "label2": "Value2"} > 1 1712648163950 > so it stores above series all the time or value/timestamp? > > > 2) Can some fairly long metric names cause a memory issue? If it is > storing metrics' names every single time, then will it store metrics' > names, labels, values and timestamps? > > -- > 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/CAOrgXN%2B26LDfk%2BHW%3DKQ5%2Bx8EkwRBw-HZ_pPuKOFyRU21QvXkrQ%40mail.gmail.com > <https://groups.google.com/d/msgid/prometheus-users/CAOrgXN%2B26LDfk%2BHW%3DKQ5%2Bx8EkwRBw-HZ_pPuKOFyRU21QvXkrQ%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > -- 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/CABbyFmpK3Ktq3sS2V8%2B4o4Fr9%3DVaRrJiGrPauzCJ5vteUK2x%3Dg%40mail.gmail.com.

