Review feedback

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
This commit is contained in:
Bryan Boreham 2022-12-15 18:29:44 +00:00
parent 463f5cafdd
commit 0853250695
3 changed files with 3 additions and 3 deletions

View file

@ -422,7 +422,7 @@ type Labels interface {
type SampleIterable interface { type SampleIterable interface {
// Iterator returns an iterator of the data of the series. // Iterator returns an iterator of the data of the series.
// The iterator passed as argument is for re-use. // The iterator passed as argument is for re-use, if not nil.
// Depending on implementation, the iterator can // Depending on implementation, the iterator can
// be re-used or a new iterator can be allocated. // be re-used or a new iterator can be allocated.
Iterator(chunkenc.Iterator) chunkenc.Iterator Iterator(chunkenc.Iterator) chunkenc.Iterator

View file

@ -287,7 +287,7 @@ func (s *seriesToChunkEncoder) Iterator(it chunks.Iterator) chunks.Iterator {
mint := int64(math.MaxInt64) mint := int64(math.MaxInt64)
maxt := int64(math.MinInt64) maxt := int64(math.MinInt64)
chks := []chunks.Meta{} var chks []chunks.Meta
lcsi, existing := it.(*listChunkSeriesIterator) lcsi, existing := it.(*listChunkSeriesIterator)
if existing { if existing {
chks = lcsi.chks[:0] chks = lcsi.chks[:0]

View file

@ -426,7 +426,7 @@ func labelNamesWithMatchers(r IndexReader, matchers ...*labels.Matcher) ([]strin
return r.LabelNamesFor(postings...) return r.LabelNamesFor(postings...)
} }
// These are the things fetched when we move from one series to another. // seriesData, used inside other iterators, are updated when we move from one series to another.
type seriesData struct { type seriesData struct {
chks []chunks.Meta chks []chunks.Meta
intervals tombstones.Intervals intervals tombstones.Intervals