MCPcopy Index your code
hub / github.com/prometheus/prometheus / NewDecoder

Function NewDecoder

tsdb/compression/compression.go:99–106  ·  view source on GitHub ↗

NewDecoder creates a new Decoder.

()

Source from the content-addressed store, hash-verified

97
98// NewDecoder creates a new Decoder.
99func NewDecoder() *Decoder {
100 d := &Decoder{}
101
102 // Calling zstd.NewReader with a nil io.Reader and no options cannot return an error.
103 r, _ := zstd.NewReader(nil)
104 d.r = r
105 return d
106}
107
108// Decode returns the decoded form of src or error, given expected compression type.
109//

Callers 4

TestEncodeDecodeFunction · 0.92
BenchmarkDecode_SamplesFunction · 0.92

Calls

no outgoing calls

Tested by 4

TestEncodeDecodeFunction · 0.74
BenchmarkDecode_SamplesFunction · 0.74

Used in the wild real call sites across dependent graphs

searching dependent graphs…