Fix tests

Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com>
This commit is contained in:
Ganesh Vernekar 2021-10-05 14:21:24 +05:30
parent 59d77ff16d
commit 9d81b2d610
No known key found for this signature in database
GPG key ID: 0F8729A5EB59B965

View file

@ -609,7 +609,13 @@ func (s *memSeries) appendHistogram(t int64, sh histogram.SparseHistogram, appen
// We check for Appendable before appendPreprocessor because in case it ends up creating a new chunk,
// we need to know if there was also a counter reset or not to set the meta properly.
app, _ := s.app.(*chunkenc.HistoAppender)
posInterjections, negInterjections, ok, counterReset := app.Appendable(sh)
var (
posInterjections, negInterjections []chunkenc.Interjection
ok, counterReset bool
)
if app != nil {
posInterjections, negInterjections, ok, counterReset = app.Appendable(sh)
}
c, sampleInOrder, chunkCreated := s.appendPreprocessor(t, chunkenc.EncSHS, chunkDiskMapper)
if !sampleInOrder {