getMemorySeriesMetric returns the total number of in-memory series across all open TSDBs.
()
| 3115 | |
| 3116 | // getMemorySeriesMetric returns the total number of in-memory series across all open TSDBs. |
| 3117 | func (i *Ingester) getMemorySeriesMetric() float64 { |
| 3118 | if err := i.checkRunning(); err != nil { |
| 3119 | return 0 |
| 3120 | } |
| 3121 | |
| 3122 | i.stoppedMtx.RLock() |
| 3123 | defer i.stoppedMtx.RUnlock() |
| 3124 | |
| 3125 | count := uint64(0) |
| 3126 | for _, db := range i.TSDBState.dbs { |
| 3127 | count += db.Head().NumSeries() |
| 3128 | } |
| 3129 | |
| 3130 | return float64(count) |
| 3131 | } |
| 3132 | |
| 3133 | // getOldestUnshippedBlockMetric returns the unix timestamp of the oldest unshipped block or |
| 3134 | // 0 if all blocks have been shipped. |
nothing calls this directly
no test coverage detected