model

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ReadRequest_ResponseType_name = map[int32]string{
		0: "SAMPLES",
		1: "STREAMED_XOR_CHUNKS",
	}
	ReadRequest_ResponseType_value = map[string]int32{
		"SAMPLES":             0,
		"STREAMED_XOR_CHUNKS": 1,
	}
)

Enum value maps for ReadRequest_ResponseType.

View Source
var (
	MetricMetadata_MetricType_name = map[int32]string{
		0: "UNKNOWN",
		1: "COUNTER",
		2: "GAUGE",
		3: "HISTOGRAM",
		4: "GAUGEHISTOGRAM",
		5: "SUMMARY",
		6: "INFO",
		7: "STATESET",
	}
	MetricMetadata_MetricType_value = map[string]int32{
		"UNKNOWN":        0,
		"COUNTER":        1,
		"GAUGE":          2,
		"HISTOGRAM":      3,
		"GAUGEHISTOGRAM": 4,
		"SUMMARY":        5,
		"INFO":           6,
		"STATESET":       7,
	}
)

Enum value maps for MetricMetadata_MetricType.

View Source
var (
	Histogram_ResetHint_name = map[int32]string{
		0: "UNKNOWN",
		1: "YES",
		2: "NO",
		3: "GAUGE",
	}
	Histogram_ResetHint_value = map[string]int32{
		"UNKNOWN": 0,
		"YES":     1,
		"NO":      2,
		"GAUGE":   3,
	}
)

Enum value maps for Histogram_ResetHint.

View Source
var (
	LabelMatcher_Type_name = map[int32]string{
		0: "EQ",
		1: "NEQ",
		2: "RE",
		3: "NRE",
	}
	LabelMatcher_Type_value = map[string]int32{
		"EQ":  0,
		"NEQ": 1,
		"RE":  2,
		"NRE": 3,
	}
)

Enum value maps for LabelMatcher_Type.

View Source
var (
	Chunk_Encoding_name = map[int32]string{
		0: "UNKNOWN",
		1: "XOR",
		2: "HISTOGRAM",
		3: "FLOAT_HISTOGRAM",
	}
	Chunk_Encoding_value = map[string]int32{
		"UNKNOWN":         0,
		"XOR":             1,
		"HISTOGRAM":       2,
		"FLOAT_HISTOGRAM": 3,
	}
)

Enum value maps for Chunk_Encoding.

View Source
var File_remote_proto protoreflect.FileDescriptor
View Source
var File_types_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type BucketSpan

type BucketSpan struct {
	Offset int32  `protobuf:"zigzag32,1,opt,name=offset,proto3" json:"offset,omitempty"` // Gap to previous span, or starting point for 1st span (which can be negative).
	Length uint32 `protobuf:"varint,2,opt,name=length,proto3" json:"length,omitempty"`   // Length of consecutive buckets.
	// contains filtered or unexported fields
}

A BucketSpan defines a number of consecutive buckets with their offset. Logically, it would be more straightforward to include the bucket counts in the Span. However, the protobuf representation is more compact in the way the data is structured here (with all the buckets in a single array separate from the Spans).

func (*BucketSpan) Descriptor deprecated

func (*BucketSpan) Descriptor() ([]byte, []int)

Deprecated: Use BucketSpan.ProtoReflect.Descriptor instead.

func (*BucketSpan) GetLength

func (x *BucketSpan) GetLength() uint32

func (*BucketSpan) GetOffset

func (x *BucketSpan) GetOffset() int32

func (*BucketSpan) MarshalToSizedBufferVT

func (m *BucketSpan) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*BucketSpan) MarshalToVT

func (m *BucketSpan) MarshalToVT(dAtA []byte) (int, error)

func (*BucketSpan) MarshalVT

func (m *BucketSpan) MarshalVT() (dAtA []byte, err error)

func (*BucketSpan) ProtoMessage

func (*BucketSpan) ProtoMessage()

func (*BucketSpan) ProtoReflect

func (x *BucketSpan) ProtoReflect() protoreflect.Message

func (*BucketSpan) Reset

func (x *BucketSpan) Reset()

func (*BucketSpan) SizeVT

func (m *BucketSpan) SizeVT() (n int)

func (*BucketSpan) String

func (x *BucketSpan) String() string

type Chunk

type Chunk struct {
	MinTimeMs int64          `protobuf:"varint,1,opt,name=min_time_ms,json=minTimeMs,proto3" json:"min_time_ms,omitempty"`
	MaxTimeMs int64          `protobuf:"varint,2,opt,name=max_time_ms,json=maxTimeMs,proto3" json:"max_time_ms,omitempty"`
	Type      Chunk_Encoding `protobuf:"varint,3,opt,name=type,proto3,enum=prometheus.Chunk_Encoding" json:"type,omitempty"`
	Data      []byte         `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

Chunk represents a TSDB chunk. Time range [min, max] is inclusive.

func (*Chunk) Descriptor deprecated

func (*Chunk) Descriptor() ([]byte, []int)

Deprecated: Use Chunk.ProtoReflect.Descriptor instead.

func (*Chunk) GetData

func (x *Chunk) GetData() []byte

func (*Chunk) GetMaxTimeMs

func (x *Chunk) GetMaxTimeMs() int64

func (*Chunk) GetMinTimeMs

func (x *Chunk) GetMinTimeMs() int64

func (*Chunk) GetType

func (x *Chunk) GetType() Chunk_Encoding

func (*Chunk) MarshalToSizedBufferVT

func (m *Chunk) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Chunk) MarshalToVT

func (m *Chunk) MarshalToVT(dAtA []byte) (int, error)

func (*Chunk) MarshalVT

func (m *Chunk) MarshalVT() (dAtA []byte, err error)

func (*Chunk) ProtoMessage

func (*Chunk) ProtoMessage()

func (*Chunk) ProtoReflect

func (x *Chunk) ProtoReflect() protoreflect.Message

func (*Chunk) Reset

func (x *Chunk) Reset()

func (*Chunk) SizeVT

func (m *Chunk) SizeVT() (n int)

func (*Chunk) String

func (x *Chunk) String() string

type Chunk_Encoding

type Chunk_Encoding int32

We require this to match chunkenc.Encoding.

const (
	Chunk_UNKNOWN         Chunk_Encoding = 0
	Chunk_XOR             Chunk_Encoding = 1
	Chunk_HISTOGRAM       Chunk_Encoding = 2
	Chunk_FLOAT_HISTOGRAM Chunk_Encoding = 3
)

func (Chunk_Encoding) Descriptor

func (Chunk_Encoding) Enum

func (x Chunk_Encoding) Enum() *Chunk_Encoding

func (Chunk_Encoding) EnumDescriptor deprecated

func (Chunk_Encoding) EnumDescriptor() ([]byte, []int)

Deprecated: Use Chunk_Encoding.Descriptor instead.

func (Chunk_Encoding) Number

func (Chunk_Encoding) String

func (x Chunk_Encoding) String() string

func (Chunk_Encoding) Type

type ChunkedReadResponse

type ChunkedReadResponse struct {
	ChunkedSeries []*ChunkedSeries `protobuf:"bytes,1,rep,name=chunked_series,json=chunkedSeries,proto3" json:"chunked_series,omitempty"`
	// query_index represents an index of the query from ReadRequest.queries these chunks relates to.
	QueryIndex int64 `protobuf:"varint,2,opt,name=query_index,json=queryIndex,proto3" json:"query_index,omitempty"`
	// contains filtered or unexported fields
}

ChunkedReadResponse is a response when response_type equals STREAMED_XOR_CHUNKS. We strictly stream full series after series, optionally split by time. This means that a single frame can contain partition of the single series, but once a new series is started to be streamed it means that no more chunks will be sent for previous one. Series are returned sorted in the same way TSDB block are internally.

func (*ChunkedReadResponse) Descriptor deprecated

func (*ChunkedReadResponse) Descriptor() ([]byte, []int)

Deprecated: Use ChunkedReadResponse.ProtoReflect.Descriptor instead.

func (*ChunkedReadResponse) GetChunkedSeries

func (x *ChunkedReadResponse) GetChunkedSeries() []*ChunkedSeries

func (*ChunkedReadResponse) GetQueryIndex

func (x *ChunkedReadResponse) GetQueryIndex() int64

func (*ChunkedReadResponse) MarshalToSizedBufferVT

func (m *ChunkedReadResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*ChunkedReadResponse) MarshalToVT

func (m *ChunkedReadResponse) MarshalToVT(dAtA []byte) (int, error)

func (*ChunkedReadResponse) MarshalVT

func (m *ChunkedReadResponse) MarshalVT() (dAtA []byte, err error)

func (*ChunkedReadResponse) ProtoMessage

func (*ChunkedReadResponse) ProtoMessage()

func (*ChunkedReadResponse) ProtoReflect

func (x *ChunkedReadResponse) ProtoReflect() protoreflect.Message

func (*ChunkedReadResponse) Reset

func (x *ChunkedReadResponse) Reset()

func (*ChunkedReadResponse) SizeVT

func (m *ChunkedReadResponse) SizeVT() (n int)

func (*ChunkedReadResponse) String

func (x *ChunkedReadResponse) String() string

type ChunkedSeries

type ChunkedSeries struct {

	// Labels should be sorted.
	Labels []*Label `protobuf:"bytes,1,rep,name=labels,proto3" json:"labels,omitempty"`
	// Chunks will be in start time order and may overlap.
	Chunks []*Chunk `protobuf:"bytes,2,rep,name=chunks,proto3" json:"chunks,omitempty"`
	// contains filtered or unexported fields
}

ChunkedSeries represents single, encoded time series.

func (*ChunkedSeries) Descriptor deprecated

func (*ChunkedSeries) Descriptor() ([]byte, []int)

Deprecated: Use ChunkedSeries.ProtoReflect.Descriptor instead.

func (*ChunkedSeries) GetChunks

func (x *ChunkedSeries) GetChunks() []*Chunk

func (*ChunkedSeries) GetLabels

func (x *ChunkedSeries) GetLabels() []*Label

func (*ChunkedSeries) MarshalToSizedBufferVT

func (m *ChunkedSeries) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*ChunkedSeries) MarshalToVT

func (m *ChunkedSeries) MarshalToVT(dAtA []byte) (int, error)

func (*ChunkedSeries) MarshalVT

func (m *ChunkedSeries) MarshalVT() (dAtA []byte, err error)

func (*ChunkedSeries) ProtoMessage

func (*ChunkedSeries) ProtoMessage()

func (*ChunkedSeries) ProtoReflect

func (x *ChunkedSeries) ProtoReflect() protoreflect.Message

func (*ChunkedSeries) Reset

func (x *ChunkedSeries) Reset()

func (*ChunkedSeries) SizeVT

func (m *ChunkedSeries) SizeVT() (n int)

func (*ChunkedSeries) String

func (x *ChunkedSeries) String() string

type Exemplar

type Exemplar struct {

	// Optional, can be empty.
	Labels []*Label `protobuf:"bytes,1,rep,name=labels,proto3" json:"labels,omitempty"`
	Value  float64  `protobuf:"fixed64,2,opt,name=value,proto3" json:"value,omitempty"`
	// timestamp is in ms format, see model/timestamp/timestamp.go for
	// conversion from time.Time to Prometheus timestamp.
	Timestamp int64 `protobuf:"varint,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*Exemplar) Descriptor deprecated

func (*Exemplar) Descriptor() ([]byte, []int)

Deprecated: Use Exemplar.ProtoReflect.Descriptor instead.

func (*Exemplar) GetLabels

func (x *Exemplar) GetLabels() []*Label

func (*Exemplar) GetTimestamp

func (x *Exemplar) GetTimestamp() int64

func (*Exemplar) GetValue

func (x *Exemplar) GetValue() float64

func (*Exemplar) MarshalToSizedBufferVT

func (m *Exemplar) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Exemplar) MarshalToVT

func (m *Exemplar) MarshalToVT(dAtA []byte) (int, error)

func (*Exemplar) MarshalVT

func (m *Exemplar) MarshalVT() (dAtA []byte, err error)

func (*Exemplar) ProtoMessage

func (*Exemplar) ProtoMessage()

func (*Exemplar) ProtoReflect

func (x *Exemplar) ProtoReflect() protoreflect.Message

func (*Exemplar) Reset

func (x *Exemplar) Reset()

func (*Exemplar) SizeVT

func (m *Exemplar) SizeVT() (n int)

func (*Exemplar) String

func (x *Exemplar) String() string

type Histogram

type Histogram struct {

	// Types that are assignable to Count:
	//
	//	*Histogram_CountInt
	//	*Histogram_CountFloat
	Count isHistogram_Count `protobuf_oneof:"count"`
	Sum   float64           `protobuf:"fixed64,3,opt,name=sum,proto3" json:"sum,omitempty"` // Sum of observations in the histogram.
	// The schema defines the bucket schema. Currently, valid numbers
	// are -4 <= n <= 8. They are all for base-2 bucket schemas, where 1
	// is a bucket boundary in each case, and then each power of two is
	// divided into 2^n logarithmic buckets. Or in other words, each
	// bucket boundary is the previous boundary times 2^(2^-n). In the
	// future, more bucket schemas may be added using numbers < -4 or >
	// 8.
	Schema        int32   `protobuf:"zigzag32,4,opt,name=schema,proto3" json:"schema,omitempty"`
	ZeroThreshold float64 `protobuf:"fixed64,5,opt,name=zero_threshold,json=zeroThreshold,proto3" json:"zero_threshold,omitempty"` // Breadth of the zero bucket.
	// Types that are assignable to ZeroCount:
	//
	//	*Histogram_ZeroCountInt
	//	*Histogram_ZeroCountFloat
	ZeroCount isHistogram_ZeroCount `protobuf_oneof:"zero_count"`
	// Negative Buckets.
	NegativeSpans []*BucketSpan `protobuf:"bytes,8,rep,name=negative_spans,json=negativeSpans,proto3" json:"negative_spans,omitempty"`
	// Use either "negative_deltas" or "negative_counts", the former for
	// regular histograms with integer counts, the latter for float
	// histograms.
	NegativeDeltas []int64   `protobuf:"zigzag64,9,rep,packed,name=negative_deltas,json=negativeDeltas,proto3" json:"negative_deltas,omitempty"` // Count delta of each bucket compared to previous one (or to zero for 1st bucket).
	NegativeCounts []float64 `protobuf:"fixed64,10,rep,packed,name=negative_counts,json=negativeCounts,proto3" json:"negative_counts,omitempty"` // Absolute count of each bucket.
	// Positive Buckets.
	PositiveSpans []*BucketSpan `protobuf:"bytes,11,rep,name=positive_spans,json=positiveSpans,proto3" json:"positive_spans,omitempty"`
	// Use either "positive_deltas" or "positive_counts", the former for
	// regular histograms with integer counts, the latter for float
	// histograms.
	PositiveDeltas []int64             `protobuf:"zigzag64,12,rep,packed,name=positive_deltas,json=positiveDeltas,proto3" json:"positive_deltas,omitempty"` // Count delta of each bucket compared to previous one (or to zero for 1st bucket).
	PositiveCounts []float64           `protobuf:"fixed64,13,rep,packed,name=positive_counts,json=positiveCounts,proto3" json:"positive_counts,omitempty"`  // Absolute count of each bucket.
	ResetHint      Histogram_ResetHint ``                                                                                                                   /* 126-byte string literal not displayed */
	// timestamp is in ms format, see model/timestamp/timestamp.go for
	// conversion from time.Time to Prometheus timestamp.
	Timestamp int64 `protobuf:"varint,15,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

A native histogram, also known as a sparse histogram. Original design doc: https://docs.google.com/document/d/1cLNv3aufPZb3fNfaJgdaRBZsInZKKIHo9E6HinJVbpM/edit The appendix of this design doc also explains the concept of float histograms. This Histogram message can represent both, the usual integer histogram as well as a float histogram.

func (*Histogram) Descriptor deprecated

func (*Histogram) Descriptor() ([]byte, []int)

Deprecated: Use Histogram.ProtoReflect.Descriptor instead.

func (*Histogram) GetCount

func (m *Histogram) GetCount() isHistogram_Count

func (*Histogram) GetCountFloat

func (x *Histogram) GetCountFloat() float64

func (*Histogram) GetCountInt

func (x *Histogram) GetCountInt() uint64

func (*Histogram) GetNegativeCounts

func (x *Histogram) GetNegativeCounts() []float64

func (*Histogram) GetNegativeDeltas

func (x *Histogram) GetNegativeDeltas() []int64

func (*Histogram) GetNegativeSpans

func (x *Histogram) GetNegativeSpans() []*BucketSpan

func (*Histogram) GetPositiveCounts

func (x *Histogram) GetPositiveCounts() []float64

func (*Histogram) GetPositiveDeltas

func (x *Histogram) GetPositiveDeltas() []int64

func (*Histogram) GetPositiveSpans

func (x *Histogram) GetPositiveSpans() []*BucketSpan

func (*Histogram) GetResetHint

func (x *Histogram) GetResetHint() Histogram_ResetHint

func (*Histogram) GetSchema

func (x *Histogram) GetSchema() int32

func (*Histogram) GetSum

func (x *Histogram) GetSum() float64

func (*Histogram) GetTimestamp

func (x *Histogram) GetTimestamp() int64

func (*Histogram) GetZeroCount

func (m *Histogram) GetZeroCount() isHistogram_ZeroCount

func (*Histogram) GetZeroCountFloat

func (x *Histogram) GetZeroCountFloat() float64

func (*Histogram) GetZeroCountInt

func (x *Histogram) GetZeroCountInt() uint64

func (*Histogram) GetZeroThreshold

func (x *Histogram) GetZeroThreshold() float64

func (*Histogram) MarshalToSizedBufferVT

func (m *Histogram) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Histogram) MarshalToVT

func (m *Histogram) MarshalToVT(dAtA []byte) (int, error)

func (*Histogram) MarshalVT

func (m *Histogram) MarshalVT() (dAtA []byte, err error)

func (*Histogram) ProtoMessage

func (*Histogram) ProtoMessage()

func (*Histogram) ProtoReflect

func (x *Histogram) ProtoReflect() protoreflect.Message

func (*Histogram) Reset

func (x *Histogram) Reset()

func (*Histogram) SizeVT

func (m *Histogram) SizeVT() (n int)

func (*Histogram) String

func (x *Histogram) String() string

type Histogram_CountFloat

type Histogram_CountFloat struct {
	CountFloat float64 `protobuf:"fixed64,2,opt,name=count_float,json=countFloat,proto3,oneof"`
}

func (*Histogram_CountFloat) MarshalToSizedBufferVT

func (m *Histogram_CountFloat) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Histogram_CountFloat) MarshalToVT

func (m *Histogram_CountFloat) MarshalToVT(dAtA []byte) (int, error)

func (*Histogram_CountFloat) SizeVT

func (m *Histogram_CountFloat) SizeVT() (n int)

type Histogram_CountInt

type Histogram_CountInt struct {
	CountInt uint64 `protobuf:"varint,1,opt,name=count_int,json=countInt,proto3,oneof"`
}

func (*Histogram_CountInt) MarshalToSizedBufferVT

func (m *Histogram_CountInt) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Histogram_CountInt) MarshalToVT

func (m *Histogram_CountInt) MarshalToVT(dAtA []byte) (int, error)

func (*Histogram_CountInt) SizeVT

func (m *Histogram_CountInt) SizeVT() (n int)

type Histogram_ResetHint

type Histogram_ResetHint int32
const (
	Histogram_UNKNOWN Histogram_ResetHint = 0 // Need to test for a counter reset explicitly.
	Histogram_YES     Histogram_ResetHint = 1 // This is the 1st histogram after a counter reset.
	Histogram_NO      Histogram_ResetHint = 2 // There was no counter reset between this and the previous Histogram.
	Histogram_GAUGE   Histogram_ResetHint = 3 // This is a gauge histogram where counter resets don't happen.
)

func (Histogram_ResetHint) Descriptor

func (Histogram_ResetHint) Enum

func (Histogram_ResetHint) EnumDescriptor deprecated

func (Histogram_ResetHint) EnumDescriptor() ([]byte, []int)

Deprecated: Use Histogram_ResetHint.Descriptor instead.

func (Histogram_ResetHint) Number

func (Histogram_ResetHint) String

func (x Histogram_ResetHint) String() string

func (Histogram_ResetHint) Type

type Histogram_ZeroCountFloat

type Histogram_ZeroCountFloat struct {
	ZeroCountFloat float64 `protobuf:"fixed64,7,opt,name=zero_count_float,json=zeroCountFloat,proto3,oneof"`
}

func (*Histogram_ZeroCountFloat) MarshalToSizedBufferVT

func (m *Histogram_ZeroCountFloat) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Histogram_ZeroCountFloat) MarshalToVT

func (m *Histogram_ZeroCountFloat) MarshalToVT(dAtA []byte) (int, error)

func (*Histogram_ZeroCountFloat) SizeVT

func (m *Histogram_ZeroCountFloat) SizeVT() (n int)

type Histogram_ZeroCountInt

type Histogram_ZeroCountInt struct {
	ZeroCountInt uint64 `protobuf:"varint,6,opt,name=zero_count_int,json=zeroCountInt,proto3,oneof"`
}

func (*Histogram_ZeroCountInt) MarshalToSizedBufferVT

func (m *Histogram_ZeroCountInt) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Histogram_ZeroCountInt) MarshalToVT

func (m *Histogram_ZeroCountInt) MarshalToVT(dAtA []byte) (int, error)

func (*Histogram_ZeroCountInt) SizeVT

func (m *Histogram_ZeroCountInt) SizeVT() (n int)

type Label

type Label struct {
	Name  string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*Label) Descriptor deprecated

func (*Label) Descriptor() ([]byte, []int)

Deprecated: Use Label.ProtoReflect.Descriptor instead.

func (*Label) GetName

func (x *Label) GetName() string

func (*Label) GetValue

func (x *Label) GetValue() string

func (*Label) MarshalToSizedBufferVT

func (m *Label) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Label) MarshalToVT

func (m *Label) MarshalToVT(dAtA []byte) (int, error)

func (*Label) MarshalVT

func (m *Label) MarshalVT() (dAtA []byte, err error)

func (*Label) ProtoMessage

func (*Label) ProtoMessage()

func (*Label) ProtoReflect

func (x *Label) ProtoReflect() protoreflect.Message

func (*Label) Reset

func (x *Label) Reset()

func (*Label) SizeVT

func (m *Label) SizeVT() (n int)

func (*Label) String

func (x *Label) String() string

type LabelMatcher

type LabelMatcher struct {
	Type  LabelMatcher_Type `protobuf:"varint,1,opt,name=type,proto3,enum=prometheus.LabelMatcher_Type" json:"type,omitempty"`
	Name  string            `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Value string            `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

Matcher specifies a rule, which can match or set of labels or not.

func (*LabelMatcher) Descriptor deprecated

func (*LabelMatcher) Descriptor() ([]byte, []int)

Deprecated: Use LabelMatcher.ProtoReflect.Descriptor instead.

func (*LabelMatcher) GetName

func (x *LabelMatcher) GetName() string

func (*LabelMatcher) GetType

func (x *LabelMatcher) GetType() LabelMatcher_Type

func (*LabelMatcher) GetValue

func (x *LabelMatcher) GetValue() string

func (*LabelMatcher) MarshalToSizedBufferVT

func (m *LabelMatcher) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*LabelMatcher) MarshalToVT

func (m *LabelMatcher) MarshalToVT(dAtA []byte) (int, error)

func (*LabelMatcher) MarshalVT

func (m *LabelMatcher) MarshalVT() (dAtA []byte, err error)

func (*LabelMatcher) ProtoMessage

func (*LabelMatcher) ProtoMessage()

func (*LabelMatcher) ProtoReflect

func (x *LabelMatcher) ProtoReflect() protoreflect.Message

func (*LabelMatcher) Reset

func (x *LabelMatcher) Reset()

func (*LabelMatcher) SizeVT

func (m *LabelMatcher) SizeVT() (n int)

func (*LabelMatcher) String

func (x *LabelMatcher) String() string

type LabelMatcher_Type

type LabelMatcher_Type int32
const (
	LabelMatcher_EQ  LabelMatcher_Type = 0
	LabelMatcher_NEQ LabelMatcher_Type = 1
	LabelMatcher_RE  LabelMatcher_Type = 2
	LabelMatcher_NRE LabelMatcher_Type = 3
)

func (LabelMatcher_Type) Descriptor

func (LabelMatcher_Type) Enum

func (LabelMatcher_Type) EnumDescriptor deprecated

func (LabelMatcher_Type) EnumDescriptor() ([]byte, []int)

Deprecated: Use LabelMatcher_Type.Descriptor instead.

func (LabelMatcher_Type) Number

func (LabelMatcher_Type) String

func (x LabelMatcher_Type) String() string

func (LabelMatcher_Type) Type

type Labels

type Labels struct {
	Labels []*Label `protobuf:"bytes,1,rep,name=labels,proto3" json:"labels,omitempty"`
	// contains filtered or unexported fields
}

func (*Labels) Descriptor deprecated

func (*Labels) Descriptor() ([]byte, []int)

Deprecated: Use Labels.ProtoReflect.Descriptor instead.

func (*Labels) GetLabels

func (x *Labels) GetLabels() []*Label

func (*Labels) MarshalToSizedBufferVT

func (m *Labels) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Labels) MarshalToVT

func (m *Labels) MarshalToVT(dAtA []byte) (int, error)

func (*Labels) MarshalVT

func (m *Labels) MarshalVT() (dAtA []byte, err error)

func (*Labels) ProtoMessage

func (*Labels) ProtoMessage()

func (*Labels) ProtoReflect

func (x *Labels) ProtoReflect() protoreflect.Message

func (*Labels) Reset

func (x *Labels) Reset()

func (*Labels) SizeVT

func (m *Labels) SizeVT() (n int)

func (*Labels) String

func (x *Labels) String() string

type MetricMetadata

type MetricMetadata struct {

	// Represents the metric type, these match the set from Prometheus.
	// Refer to model/textparse/interface.go for details.
	Type             MetricMetadata_MetricType `protobuf:"varint,1,opt,name=type,proto3,enum=prometheus.MetricMetadata_MetricType" json:"type,omitempty"`
	MetricFamilyName string                    `protobuf:"bytes,2,opt,name=metric_family_name,json=metricFamilyName,proto3" json:"metric_family_name,omitempty"`
	Help             string                    `protobuf:"bytes,4,opt,name=help,proto3" json:"help,omitempty"`
	Unit             string                    `protobuf:"bytes,5,opt,name=unit,proto3" json:"unit,omitempty"`
	// contains filtered or unexported fields
}

func (*MetricMetadata) Descriptor deprecated

func (*MetricMetadata) Descriptor() ([]byte, []int)

Deprecated: Use MetricMetadata.ProtoReflect.Descriptor instead.

func (*MetricMetadata) GetHelp

func (x *MetricMetadata) GetHelp() string

func (*MetricMetadata) GetMetricFamilyName

func (x *MetricMetadata) GetMetricFamilyName() string

func (*MetricMetadata) GetType

func (*MetricMetadata) GetUnit

func (x *MetricMetadata) GetUnit() string

func (*MetricMetadata) MarshalToSizedBufferVT

func (m *MetricMetadata) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*MetricMetadata) MarshalToVT

func (m *MetricMetadata) MarshalToVT(dAtA []byte) (int, error)

func (*MetricMetadata) MarshalVT

func (m *MetricMetadata) MarshalVT() (dAtA []byte, err error)

func (*MetricMetadata) ProtoMessage

func (*MetricMetadata) ProtoMessage()

func (*MetricMetadata) ProtoReflect

func (x *MetricMetadata) ProtoReflect() protoreflect.Message

func (*MetricMetadata) Reset

func (x *MetricMetadata) Reset()

func (*MetricMetadata) SizeVT

func (m *MetricMetadata) SizeVT() (n int)

func (*MetricMetadata) String

func (x *MetricMetadata) String() string

type MetricMetadata_MetricType

type MetricMetadata_MetricType int32
const (
	MetricMetadata_UNKNOWN        MetricMetadata_MetricType = 0
	MetricMetadata_COUNTER        MetricMetadata_MetricType = 1
	MetricMetadata_GAUGE          MetricMetadata_MetricType = 2
	MetricMetadata_HISTOGRAM      MetricMetadata_MetricType = 3
	MetricMetadata_GAUGEHISTOGRAM MetricMetadata_MetricType = 4
	MetricMetadata_SUMMARY        MetricMetadata_MetricType = 5
	MetricMetadata_INFO           MetricMetadata_MetricType = 6
	MetricMetadata_STATESET       MetricMetadata_MetricType = 7
)

func (MetricMetadata_MetricType) Descriptor

func (MetricMetadata_MetricType) Enum

func (MetricMetadata_MetricType) EnumDescriptor deprecated

func (MetricMetadata_MetricType) EnumDescriptor() ([]byte, []int)

Deprecated: Use MetricMetadata_MetricType.Descriptor instead.

func (MetricMetadata_MetricType) Number

func (MetricMetadata_MetricType) String

func (x MetricMetadata_MetricType) String() string

func (MetricMetadata_MetricType) Type

type Query

type Query struct {
	StartTimestampMs int64           `protobuf:"varint,1,opt,name=start_timestamp_ms,json=startTimestampMs,proto3" json:"start_timestamp_ms,omitempty"`
	EndTimestampMs   int64           `protobuf:"varint,2,opt,name=end_timestamp_ms,json=endTimestampMs,proto3" json:"end_timestamp_ms,omitempty"`
	Matchers         []*LabelMatcher `protobuf:"bytes,3,rep,name=matchers,proto3" json:"matchers,omitempty"`
	Hints            *ReadHints      `protobuf:"bytes,4,opt,name=hints,proto3" json:"hints,omitempty"`
	// contains filtered or unexported fields
}

func (*Query) Descriptor deprecated

func (*Query) Descriptor() ([]byte, []int)

Deprecated: Use Query.ProtoReflect.Descriptor instead.

func (*Query) GetEndTimestampMs

func (x *Query) GetEndTimestampMs() int64

func (*Query) GetHints

func (x *Query) GetHints() *ReadHints

func (*Query) GetMatchers

func (x *Query) GetMatchers() []*LabelMatcher

func (*Query) GetStartTimestampMs

func (x *Query) GetStartTimestampMs() int64

func (*Query) MarshalToSizedBufferVT

func (m *Query) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Query) MarshalToVT

func (m *Query) MarshalToVT(dAtA []byte) (int, error)

func (*Query) MarshalVT

func (m *Query) MarshalVT() (dAtA []byte, err error)

func (*Query) ProtoMessage

func (*Query) ProtoMessage()

func (*Query) ProtoReflect

func (x *Query) ProtoReflect() protoreflect.Message

func (*Query) Reset

func (x *Query) Reset()

func (*Query) SizeVT

func (m *Query) SizeVT() (n int)

func (*Query) String

func (x *Query) String() string

type QueryResult

type QueryResult struct {

	// Samples within a time series must be ordered by time.
	Timeseries []*TimeSeries `protobuf:"bytes,1,rep,name=timeseries,proto3" json:"timeseries,omitempty"`
	// contains filtered or unexported fields
}

func (*QueryResult) Descriptor deprecated

func (*QueryResult) Descriptor() ([]byte, []int)

Deprecated: Use QueryResult.ProtoReflect.Descriptor instead.

func (*QueryResult) GetTimeseries

func (x *QueryResult) GetTimeseries() []*TimeSeries

func (*QueryResult) MarshalToSizedBufferVT

func (m *QueryResult) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*QueryResult) MarshalToVT

func (m *QueryResult) MarshalToVT(dAtA []byte) (int, error)

func (*QueryResult) MarshalVT

func (m *QueryResult) MarshalVT() (dAtA []byte, err error)

func (*QueryResult) ProtoMessage

func (*QueryResult) ProtoMessage()

func (*QueryResult) ProtoReflect

func (x *QueryResult) ProtoReflect() protoreflect.Message

func (*QueryResult) Reset

func (x *QueryResult) Reset()

func (*QueryResult) SizeVT

func (m *QueryResult) SizeVT() (n int)

func (*QueryResult) String

func (x *QueryResult) String() string

type ReadHints

type ReadHints struct {
	StepMs   int64    `protobuf:"varint,1,opt,name=step_ms,json=stepMs,proto3" json:"step_ms,omitempty"`    // Query step size in milliseconds.
	Func     string   `protobuf:"bytes,2,opt,name=func,proto3" json:"func,omitempty"`                       // String representation of surrounding function or aggregation.
	StartMs  int64    `protobuf:"varint,3,opt,name=start_ms,json=startMs,proto3" json:"start_ms,omitempty"` // Start time in milliseconds.
	EndMs    int64    `protobuf:"varint,4,opt,name=end_ms,json=endMs,proto3" json:"end_ms,omitempty"`       // End time in milliseconds.
	Grouping []string `protobuf:"bytes,5,rep,name=grouping,proto3" json:"grouping,omitempty"`               // List of label names used in aggregation.
	By       bool     `protobuf:"varint,6,opt,name=by,proto3" json:"by,omitempty"`                          // Indicate whether it is without or by.
	RangeMs  int64    `protobuf:"varint,7,opt,name=range_ms,json=rangeMs,proto3" json:"range_ms,omitempty"` // Range vector selector range in milliseconds.
	// contains filtered or unexported fields
}

func (*ReadHints) Descriptor deprecated

func (*ReadHints) Descriptor() ([]byte, []int)

Deprecated: Use ReadHints.ProtoReflect.Descriptor instead.

func (*ReadHints) GetBy

func (x *ReadHints) GetBy() bool

func (*ReadHints) GetEndMs

func (x *ReadHints) GetEndMs() int64

func (*ReadHints) GetFunc

func (x *ReadHints) GetFunc() string

func (*ReadHints) GetGrouping

func (x *ReadHints) GetGrouping() []string

func (*ReadHints) GetRangeMs

func (x *ReadHints) GetRangeMs() int64

func (*ReadHints) GetStartMs

func (x *ReadHints) GetStartMs() int64

func (*ReadHints) GetStepMs

func (x *ReadHints) GetStepMs() int64

func (*ReadHints) MarshalToSizedBufferVT

func (m *ReadHints) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*ReadHints) MarshalToVT

func (m *ReadHints) MarshalToVT(dAtA []byte) (int, error)

func (*ReadHints) MarshalVT

func (m *ReadHints) MarshalVT() (dAtA []byte, err error)

func (*ReadHints) ProtoMessage

func (*ReadHints) ProtoMessage()

func (*ReadHints) ProtoReflect

func (x *ReadHints) ProtoReflect() protoreflect.Message

func (*ReadHints) Reset

func (x *ReadHints) Reset()

func (*ReadHints) SizeVT

func (m *ReadHints) SizeVT() (n int)

func (*ReadHints) String

func (x *ReadHints) String() string

type ReadRequest

type ReadRequest struct {
	Queries []*Query `protobuf:"bytes,1,rep,name=queries,proto3" json:"queries,omitempty"`
	// accepted_response_types allows negotiating the content type of the response.
	//
	// Response types are taken from the list in the FIFO order. If no response type in `accepted_response_types` is
	// implemented by server, error is returned.
	// For request that do not contain `accepted_response_types` field the SAMPLES response type will be used.
	AcceptedResponseTypes []ReadRequest_ResponseType `` /* 175-byte string literal not displayed */
	// contains filtered or unexported fields
}

ReadRequest represents a remote read request.

func (*ReadRequest) Descriptor deprecated

func (*ReadRequest) Descriptor() ([]byte, []int)

Deprecated: Use ReadRequest.ProtoReflect.Descriptor instead.

func (*ReadRequest) GetAcceptedResponseTypes

func (x *ReadRequest) GetAcceptedResponseTypes() []ReadRequest_ResponseType

func (*ReadRequest) GetQueries

func (x *ReadRequest) GetQueries() []*Query

func (*ReadRequest) MarshalToSizedBufferVT

func (m *ReadRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*ReadRequest) MarshalToVT

func (m *ReadRequest) MarshalToVT(dAtA []byte) (int, error)

func (*ReadRequest) MarshalVT

func (m *ReadRequest) MarshalVT() (dAtA []byte, err error)

func (*ReadRequest) ProtoMessage

func (*ReadRequest) ProtoMessage()

func (*ReadRequest) ProtoReflect

func (x *ReadRequest) ProtoReflect() protoreflect.Message

func (*ReadRequest) Reset

func (x *ReadRequest) Reset()

func (*ReadRequest) SizeVT

func (m *ReadRequest) SizeVT() (n int)

func (*ReadRequest) String

func (x *ReadRequest) String() string

type ReadRequest_ResponseType

type ReadRequest_ResponseType int32
const (
	// Server will return a single ReadResponse message with matched series that includes list of raw samples.
	// It's recommended to use streamed response types instead.
	//
	// Response headers:
	// Content-Type: "application/x-protobuf"
	// Content-Encoding: "snappy"
	ReadRequest_SAMPLES ReadRequest_ResponseType = 0
	// Server will stream a delimited ChunkedReadResponse message that
	// contains XOR or HISTOGRAM(!) encoded chunks for a single series.
	// Each message is following varint size and fixed size bigendian
	// uint32 for CRC32 Castagnoli checksum.
	//
	// Response headers:
	// Content-Type: "application/x-streamed-protobuf; proto=prometheus.ChunkedReadResponse"
	// Content-Encoding: ""
	ReadRequest_STREAMED_XOR_CHUNKS ReadRequest_ResponseType = 1
)

func (ReadRequest_ResponseType) Descriptor

func (ReadRequest_ResponseType) Enum

func (ReadRequest_ResponseType) EnumDescriptor deprecated

func (ReadRequest_ResponseType) EnumDescriptor() ([]byte, []int)

Deprecated: Use ReadRequest_ResponseType.Descriptor instead.

func (ReadRequest_ResponseType) Number

func (ReadRequest_ResponseType) String

func (x ReadRequest_ResponseType) String() string

func (ReadRequest_ResponseType) Type

type ReadResponse

type ReadResponse struct {

	// In same order as the request's queries.
	Results []*QueryResult `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

ReadResponse is a response when response_type equals SAMPLES.

func (*ReadResponse) Descriptor deprecated

func (*ReadResponse) Descriptor() ([]byte, []int)

Deprecated: Use ReadResponse.ProtoReflect.Descriptor instead.

func (*ReadResponse) GetResults

func (x *ReadResponse) GetResults() []*QueryResult

func (*ReadResponse) MarshalToSizedBufferVT

func (m *ReadResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*ReadResponse) MarshalToVT

func (m *ReadResponse) MarshalToVT(dAtA []byte) (int, error)

func (*ReadResponse) MarshalVT

func (m *ReadResponse) MarshalVT() (dAtA []byte, err error)

func (*ReadResponse) ProtoMessage

func (*ReadResponse) ProtoMessage()

func (*ReadResponse) ProtoReflect

func (x *ReadResponse) ProtoReflect() protoreflect.Message

func (*ReadResponse) Reset

func (x *ReadResponse) Reset()

func (*ReadResponse) SizeVT

func (m *ReadResponse) SizeVT() (n int)

func (*ReadResponse) String

func (x *ReadResponse) String() string

type Sample

type Sample struct {
	Value float64 `protobuf:"fixed64,1,opt,name=value,proto3" json:"value,omitempty"`
	// timestamp is in ms format, see model/timestamp/timestamp.go for
	// conversion from time.Time to Prometheus timestamp.
	Timestamp int64 `protobuf:"varint,2,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*Sample) Descriptor deprecated

func (*Sample) Descriptor() ([]byte, []int)

Deprecated: Use Sample.ProtoReflect.Descriptor instead.

func (*Sample) GetTimestamp

func (x *Sample) GetTimestamp() int64

func (*Sample) GetValue

func (x *Sample) GetValue() float64

func (*Sample) MarshalToSizedBufferVT

func (m *Sample) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Sample) MarshalToVT

func (m *Sample) MarshalToVT(dAtA []byte) (int, error)

func (*Sample) MarshalVT

func (m *Sample) MarshalVT() (dAtA []byte, err error)

func (*Sample) ProtoMessage

func (*Sample) ProtoMessage()

func (*Sample) ProtoReflect

func (x *Sample) ProtoReflect() protoreflect.Message

func (*Sample) Reset

func (x *Sample) Reset()

func (*Sample) SizeVT

func (m *Sample) SizeVT() (n int)

func (*Sample) String

func (x *Sample) String() string

type TimeSeries

type TimeSeries struct {

	// For a timeseries to be valid, and for the samples and exemplars
	// to be ingested by the remote system properly, the labels field is required.
	Labels     []*Label     `protobuf:"bytes,1,rep,name=labels,proto3" json:"labels,omitempty"`
	Samples    []*Sample    `protobuf:"bytes,2,rep,name=samples,proto3" json:"samples,omitempty"`
	Exemplars  []*Exemplar  `protobuf:"bytes,3,rep,name=exemplars,proto3" json:"exemplars,omitempty"`
	Histograms []*Histogram `protobuf:"bytes,4,rep,name=histograms,proto3" json:"histograms,omitempty"`
	// contains filtered or unexported fields
}

TimeSeries represents samples and labels for a single time series.

func (*TimeSeries) Descriptor deprecated

func (*TimeSeries) Descriptor() ([]byte, []int)

Deprecated: Use TimeSeries.ProtoReflect.Descriptor instead.

func (*TimeSeries) GetExemplars

func (x *TimeSeries) GetExemplars() []*Exemplar

func (*TimeSeries) GetHistograms

func (x *TimeSeries) GetHistograms() []*Histogram

func (*TimeSeries) GetLabels

func (x *TimeSeries) GetLabels() []*Label

func (*TimeSeries) GetSamples

func (x *TimeSeries) GetSamples() []*Sample

func (*TimeSeries) MarshalToSizedBufferVT

func (m *TimeSeries) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*TimeSeries) MarshalToVT

func (m *TimeSeries) MarshalToVT(dAtA []byte) (int, error)

func (*TimeSeries) MarshalVT

func (m *TimeSeries) MarshalVT() (dAtA []byte, err error)

func (*TimeSeries) ProtoMessage

func (*TimeSeries) ProtoMessage()

func (*TimeSeries) ProtoReflect

func (x *TimeSeries) ProtoReflect() protoreflect.Message

func (*TimeSeries) Reset

func (x *TimeSeries) Reset()

func (*TimeSeries) SizeVT

func (m *TimeSeries) SizeVT() (n int)

func (*TimeSeries) String

func (x *TimeSeries) String() string

type WriteRequest

type WriteRequest struct {
	Timeseries []*TimeSeries     `protobuf:"bytes,1,rep,name=timeseries,proto3" json:"timeseries,omitempty"`
	Metadata   []*MetricMetadata `protobuf:"bytes,3,rep,name=metadata,proto3" json:"metadata,omitempty"`
	// contains filtered or unexported fields
}

func (*WriteRequest) Descriptor deprecated

func (*WriteRequest) Descriptor() ([]byte, []int)

Deprecated: Use WriteRequest.ProtoReflect.Descriptor instead.

func (*WriteRequest) GetMetadata

func (x *WriteRequest) GetMetadata() []*MetricMetadata

func (*WriteRequest) GetTimeseries

func (x *WriteRequest) GetTimeseries() []*TimeSeries

func (*WriteRequest) MarshalToSizedBufferVT

func (m *WriteRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*WriteRequest) MarshalToVT

func (m *WriteRequest) MarshalToVT(dAtA []byte) (int, error)

func (*WriteRequest) MarshalVT

func (m *WriteRequest) MarshalVT() (dAtA []byte, err error)

func (*WriteRequest) ProtoMessage

func (*WriteRequest) ProtoMessage()

func (*WriteRequest) ProtoReflect

func (x *WriteRequest) ProtoReflect() protoreflect.Message

func (*WriteRequest) Reset

func (x *WriteRequest) Reset()

func (*WriteRequest) SizeVT

func (m *WriteRequest) SizeVT() (n int)

func (*WriteRequest) String

func (x *WriteRequest) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL