prometheus/tsdb/index
Oleg Zaytsev cd1f8ac129
MemPostings: keep a map of label values slices (#15426)
While investigating lock contention on `MemPostings`, we saw that lots
of locking is happening in `LabelValues` and
`PostingsForLabelsMatching`, both copying the label values slices while
holding the mutex.

This adds an extra map that holds an append-only label values slice for
each one of the label names. Since the slice is append-only, it can be
copied without holding the mutex.

Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
2024-11-29 12:52:56 +01:00
..
index.go TSDB: eliminate one yolostring 2024-11-26 17:21:55 +00:00
index_test.go Upgrade to golangci-lint v1.62.0 (#15424) 2024-11-20 17:22:20 +01:00
postings.go MemPostings: keep a map of label values slices (#15426) 2024-11-29 12:52:56 +01:00
postings_test.go [PERF] TSDB: Optimize inverse matching (#14144) 2024-11-19 15:49:01 +00:00
postingsstats.go
postingsstats_test.go Upgrade golangci-lint to v1.60.1 2024-08-18 12:13:25 +02:00