mirror of
https://github.com/prometheus/prometheus.git
synced 2025-08-05 13:47:10 +02:00
chore: fix some comments (#16237)
Signed-off-by: pudongair <744355276@qq.com>
This commit is contained in:
parent
aea48f912f
commit
308c8c48c1
@ -167,7 +167,7 @@ func (m *MetricStreamingDecoder) Label(b *labels.ScratchBuilder) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// parseLabels is essentially LabelPair.Unmarshal but directly adding into scratch builder
|
||||
// parseLabel is essentially LabelPair.Unmarshal but directly adding into scratch builder
|
||||
// and reusing strings.
|
||||
func parseLabel(dAtA []byte, b *labels.ScratchBuilder) error {
|
||||
var name, value string
|
||||
|
@ -38,7 +38,7 @@ Notes:
|
||||
* `len`: Chunk size in bytes. 1 to 10 bytes long using the [`<uvarint>` encoding](https://go.dev/src/encoding/binary/varint.go).
|
||||
* `encoding`: Currently either `XOR`, `histogram`, or `floathistogram`, see [code for numerical values](https://github.com/prometheus/prometheus/blob/02d0de9987ad99dee5de21853715954fadb3239f/tsdb/chunkenc/chunk.go#L28-L47).
|
||||
* `data`: See below for each encoding.
|
||||
* `checksum`: Checksum of `encoding` and `data`. It's a [cyclic redudancy check](https://en.wikipedia.org/wiki/Cyclic_redundancy_check) with the Castagnoli polynomial, serialised as an unsigned 32 bits big endian number. Can be refered as a `CRC-32C`.
|
||||
* `checksum`: Checksum of `encoding` and `data`. It's a [cyclic redundancy check](https://en.wikipedia.org/wiki/Cyclic_redundancy_check) with the Castagnoli polynomial, serialised as an unsigned 32 bits big endian number. Can be referred as a `CRC-32C`.
|
||||
|
||||
## XOR chunk data
|
||||
|
||||
|
@ -477,7 +477,7 @@ type recordsMaker struct {
|
||||
}
|
||||
|
||||
// BenchmarkWAL_HistogramEncoding measures efficiency of encoding classic
|
||||
// histograms and native historgrams with custom buckets (NHCB).
|
||||
// histograms and native histograms with custom buckets (NHCB).
|
||||
func BenchmarkWAL_HistogramEncoding(b *testing.B) {
|
||||
initClassicRefs := func(labelCount, histograms, buckets int) (series []RefSeries, floatSamples []RefSample, histSamples []RefHistogramSample) {
|
||||
ref := chunks.HeadSeriesRef(0)
|
||||
|
@ -73,7 +73,7 @@ export const decodePanelOptionsFromURLParams = (query: string): Panel[] => {
|
||||
decodeSetting("end_input", (value) => {
|
||||
panel.visualizer.endTime = parseTime(value);
|
||||
});
|
||||
// Legacy "step_input" parameter, overriden below by
|
||||
// Legacy "step_input" parameter, overridden below by
|
||||
// "res_type" / "res_density" / "res_step" if present.
|
||||
decodeSetting("step_input", (value) => {
|
||||
if (parseInt(value) > 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user