replace stray xoroptst words

Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
This commit is contained in:
György Krajcsovits 2026-03-10 16:23:08 +01:00
parent 5e5b14c04b
commit a773d3daad
No known key found for this signature in database
GPG key ID: 47A8F9CE80FD7C7F
3 changed files with 7 additions and 7 deletions

View file

@ -77,7 +77,7 @@ type Chunk interface {
// Encoding returns the encoding type of the chunk.
// If the chunk is capable of storing ST (start timestamps), it should
// return the appropriate encoding type (e.g., EncXOROptST).
// return the appropriate encoding type (e.g., EncXOR2).
Encoding() Encoding
// Appender returns an appender to append samples to the chunk.
@ -298,7 +298,7 @@ type pool struct {
xor sync.Pool
histogram sync.Pool
floatHistogram sync.Pool
xoroptst sync.Pool
xo2 sync.Pool
}
// NewPool returns a new pool.
@ -319,7 +319,7 @@ func NewPool() Pool {
return &FloatHistogramChunk{b: bstream{}}
},
},
xoroptst: sync.Pool{
xo2: sync.Pool{
New: func() any {
return &XOR2Chunk{b: bstream{}}
},
@ -337,7 +337,7 @@ func (p *pool) Get(e Encoding, b []byte) (Chunk, error) {
case EncFloatHistogram:
c = p.floatHistogram.Get().(*FloatHistogramChunk)
case EncXOR2:
c = p.xoroptst.Get().(*XOR2Chunk)
c = p.xo2.Get().(*XOR2Chunk)
default:
return nil, fmt.Errorf("invalid chunk encoding %q", e)
}
@ -361,7 +361,7 @@ func (p *pool) Put(c Chunk) error {
sp = &p.floatHistogram
case EncXOR2:
_, ok = c.(*XOR2Chunk)
sp = &p.xoroptst
sp = &p.xo2
default:
return fmt.Errorf("invalid chunk encoding %q", c.Encoding())
}

View file

@ -101,7 +101,7 @@ func readSTHeader(b []byte) (firstSTKnown bool, firstSTChangeOn uint8) {
}
// XOR2Chunk holds XOR2 encoded samples with optional start
// timestamp per chunk or per sample. See XOROptST for the ST header format.
// timestamp per chunk or per sample.
type XOR2Chunk struct {
b bstream
}

View file

@ -7505,7 +7505,7 @@ func TestAbortBlockCompactions_AppendV2(t *testing.T) {
}
// TestCompactHeadWithSTStorage_AppendV2 ensures that when EnableSTStorage is true,
// compacted blocks contain chunks with EncXOROptST encoding for float samples.
// compacted blocks contain chunks with EncXOR2 encoding for float samples.
func TestCompactHeadWithSTStorage_AppendV2(t *testing.T) {
t.Parallel()