pbcloud

package
v0.0.0-...-deba56b Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2023 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Overview

Package pbcloud contains the Protobuf definitions used for the metrics flush RPCs.

Index

Constants

This section is empty.

Variables

View Source
var (
	MetricType_name = map[int32]string{
		0: "METRIC_TYPE_UNSPECIFIED",
		1: "METRIC_TYPE_COUNTER",
		2: "METRIC_TYPE_GAUGE",
		3: "METRIC_TYPE_RATE",
		4: "METRIC_TYPE_TREND",
	}
	MetricType_value = map[string]int32{
		"METRIC_TYPE_UNSPECIFIED": 0,
		"METRIC_TYPE_COUNTER":     1,
		"METRIC_TYPE_GAUGE":       2,
		"METRIC_TYPE_RATE":        3,
		"METRIC_TYPE_TREND":       4,
	}
)

Enum value maps for MetricType.

View Source
var File_metric_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type BucketSpan

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

BucketSpan represents the consecutive and significant (non-zero) buckets. The concept is imported from the Prometheus' native histogram. It should simplify an eventual transition to Prometheus. https://github.com/prometheus/prometheus/blob/f399f386cef3b19c48157e9678a4f50997db3f41/prompb/io/prometheus/client/metrics.proto#L115-L124

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() uint32

func (*BucketSpan) ProtoMessage

func (*BucketSpan) ProtoMessage()

func (*BucketSpan) ProtoReflect

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

func (*BucketSpan) Reset

func (x *BucketSpan) Reset()

func (*BucketSpan) String

func (x *BucketSpan) String() string

type CounterSamples

type CounterSamples struct {

	// Required.
	Values []*CounterValue `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
	// contains filtered or unexported fields
}

func (*CounterSamples) Descriptor deprecated

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

Deprecated: Use CounterSamples.ProtoReflect.Descriptor instead.

func (*CounterSamples) GetValues

func (x *CounterSamples) GetValues() []*CounterValue

func (*CounterSamples) ProtoMessage

func (*CounterSamples) ProtoMessage()

func (*CounterSamples) ProtoReflect

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

func (*CounterSamples) Reset

func (x *CounterSamples) Reset()

func (*CounterSamples) String

func (x *CounterSamples) String() string

type CounterValue

type CounterValue struct {

	// Required.
	Time  *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
	Value float64                `protobuf:"fixed64,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*CounterValue) Descriptor deprecated

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

Deprecated: Use CounterValue.ProtoReflect.Descriptor instead.

func (*CounterValue) GetTime

func (x *CounterValue) GetTime() *timestamppb.Timestamp

func (*CounterValue) GetValue

func (x *CounterValue) GetValue() float64

func (*CounterValue) ProtoMessage

func (*CounterValue) ProtoMessage()

func (*CounterValue) ProtoReflect

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

func (*CounterValue) Reset

func (x *CounterValue) Reset()

func (*CounterValue) String

func (x *CounterValue) String() string

type GaugeSamples

type GaugeSamples struct {

	// Required.
	Values []*GaugeValue `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
	// contains filtered or unexported fields
}

func (*GaugeSamples) Descriptor deprecated

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

Deprecated: Use GaugeSamples.ProtoReflect.Descriptor instead.

func (*GaugeSamples) GetValues

func (x *GaugeSamples) GetValues() []*GaugeValue

func (*GaugeSamples) ProtoMessage

func (*GaugeSamples) ProtoMessage()

func (*GaugeSamples) ProtoReflect

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

func (*GaugeSamples) Reset

func (x *GaugeSamples) Reset()

func (*GaugeSamples) String

func (x *GaugeSamples) String() string

type GaugeValue

type GaugeValue struct {

	// Required.
	Time *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
	// last observed value
	Last float64 `protobuf:"fixed64,2,opt,name=last,proto3" json:"last,omitempty"`
	// count of observations
	Count uint32 `protobuf:"varint,3,opt,name=count,proto3" json:"count,omitempty"`
	// min, max, and average of observed values
	Min float64 `protobuf:"fixed64,4,opt,name=min,proto3" json:"min,omitempty"`
	Max float64 `protobuf:"fixed64,5,opt,name=max,proto3" json:"max,omitempty"`
	Avg float64 `protobuf:"fixed64,6,opt,name=avg,proto3" json:"avg,omitempty"`
	// contains filtered or unexported fields
}

func (*GaugeValue) Descriptor deprecated

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

Deprecated: Use GaugeValue.ProtoReflect.Descriptor instead.

func (*GaugeValue) GetAvg

func (x *GaugeValue) GetAvg() float64

func (*GaugeValue) GetCount

func (x *GaugeValue) GetCount() uint32

func (*GaugeValue) GetLast

func (x *GaugeValue) GetLast() float64

func (*GaugeValue) GetMax

func (x *GaugeValue) GetMax() float64

func (*GaugeValue) GetMin

func (x *GaugeValue) GetMin() float64

func (*GaugeValue) GetTime

func (x *GaugeValue) GetTime() *timestamppb.Timestamp

func (*GaugeValue) ProtoMessage

func (*GaugeValue) ProtoMessage()

func (*GaugeValue) ProtoReflect

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

func (*GaugeValue) Reset

func (x *GaugeValue) Reset()

func (*GaugeValue) String

func (x *GaugeValue) String() string

type Label

type Label struct {

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

Label is a name-value pair.

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) ProtoMessage

func (*Label) ProtoMessage()

func (*Label) ProtoReflect

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

func (*Label) Reset

func (x *Label) Reset()

func (*Label) String

func (x *Label) String() string

type Metric

type Metric struct {

	// Required.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Required.
	// Can't be of type MetricType.METRICTYPE_UNSPECIFIED (which is zero value).
	Type MetricType `protobuf:"varint,2,opt,name=type,proto3,enum=metrics.MetricType" json:"type,omitempty"`
	// Optional.
	TimeSeries []*TimeSeries `protobuf:"bytes,3,rep,name=time_series,json=timeSeries,proto3" json:"time_series,omitempty"`
	// contains filtered or unexported fields
}

func (*Metric) Descriptor deprecated

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

Deprecated: Use Metric.ProtoReflect.Descriptor instead.

func (*Metric) GetName

func (x *Metric) GetName() string

func (*Metric) GetTimeSeries

func (x *Metric) GetTimeSeries() []*TimeSeries

func (*Metric) GetType

func (x *Metric) GetType() MetricType

func (*Metric) ProtoMessage

func (*Metric) ProtoMessage()

func (*Metric) ProtoReflect

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

func (*Metric) Reset

func (x *Metric) Reset()

func (*Metric) String

func (x *Metric) String() string

type MetricSet

type MetricSet struct {

	// Required.
	TestRunId string `protobuf:"bytes,1,opt,name=test_run_id,json=testRunId,proto3" json:"test_run_id,omitempty"`
	// Required.
	// time bucket size in seconds
	AggregationPeriod uint32 `protobuf:"varint,2,opt,name=aggregation_period,json=aggregationPeriod,proto3" json:"aggregation_period,omitempty"`
	// Required.
	Metrics []*Metric `protobuf:"bytes,3,rep,name=metrics,proto3" json:"metrics,omitempty"`
	// contains filtered or unexported fields
}

MetricSet is the top-level container type that is encoded and sent over the wire.

func (*MetricSet) Descriptor deprecated

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

Deprecated: Use MetricSet.ProtoReflect.Descriptor instead.

func (*MetricSet) GetAggregationPeriod

func (x *MetricSet) GetAggregationPeriod() uint32

func (*MetricSet) GetMetrics

func (x *MetricSet) GetMetrics() []*Metric

func (*MetricSet) GetTestRunId

func (x *MetricSet) GetTestRunId() string

func (*MetricSet) ProtoMessage

func (*MetricSet) ProtoMessage()

func (*MetricSet) ProtoReflect

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

func (*MetricSet) Reset

func (x *MetricSet) Reset()

func (*MetricSet) String

func (x *MetricSet) String() string

type MetricType

type MetricType int32

The type of a Metric.

const (
	// Metric of type METRICTYPE_UNSPECIFIED declared, but not allowed.
	// See: https://protobuf.dev/programming-guides/dos-donts/#do-include-an-unspecified-value-in-an-enum.
	MetricType_METRIC_TYPE_UNSPECIFIED MetricType = 0
	MetricType_METRIC_TYPE_COUNTER     MetricType = 1
	MetricType_METRIC_TYPE_GAUGE       MetricType = 2
	MetricType_METRIC_TYPE_RATE        MetricType = 3
	MetricType_METRIC_TYPE_TREND       MetricType = 4
)

func (MetricType) Descriptor

func (MetricType) Descriptor() protoreflect.EnumDescriptor

func (MetricType) Enum

func (x MetricType) Enum() *MetricType

func (MetricType) EnumDescriptor deprecated

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

Deprecated: Use MetricType.Descriptor instead.

func (MetricType) Number

func (x MetricType) Number() protoreflect.EnumNumber

func (MetricType) String

func (x MetricType) String() string

func (MetricType) Type

type RateSamples

type RateSamples struct {

	// Required.
	Values []*RateValue `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
	// contains filtered or unexported fields
}

func (*RateSamples) Descriptor deprecated

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

Deprecated: Use RateSamples.ProtoReflect.Descriptor instead.

func (*RateSamples) GetValues

func (x *RateSamples) GetValues() []*RateValue

func (*RateSamples) ProtoMessage

func (*RateSamples) ProtoMessage()

func (*RateSamples) ProtoReflect

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

func (*RateSamples) Reset

func (x *RateSamples) Reset()

func (*RateSamples) String

func (x *RateSamples) String() string

type RateValue

type RateValue struct {

	// Required.
	Time         *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
	NonzeroCount uint32                 `protobuf:"varint,2,opt,name=nonzero_count,json=nonzeroCount,proto3" json:"nonzero_count,omitempty"`
	TotalCount   uint32                 `protobuf:"varint,3,opt,name=total_count,json=totalCount,proto3" json:"total_count,omitempty"`
	// contains filtered or unexported fields
}

func (*RateValue) Descriptor deprecated

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

Deprecated: Use RateValue.ProtoReflect.Descriptor instead.

func (*RateValue) GetNonzeroCount

func (x *RateValue) GetNonzeroCount() uint32

func (*RateValue) GetTime

func (x *RateValue) GetTime() *timestamppb.Timestamp

func (*RateValue) GetTotalCount

func (x *RateValue) GetTotalCount() uint32

func (*RateValue) ProtoMessage

func (*RateValue) ProtoMessage()

func (*RateValue) ProtoReflect

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

func (*RateValue) Reset

func (x *RateValue) Reset()

func (*RateValue) String

func (x *RateValue) String() string

type TimeSeries

type TimeSeries struct {

	// Optional.
	Labels []*Label `protobuf:"bytes,1,rep,name=labels,proto3" json:"labels,omitempty"`
	// Required.
	//
	// Types that are assignable to Samples:
	//
	//	*TimeSeries_CounterSamples
	//	*TimeSeries_GaugeSamples
	//	*TimeSeries_RateSamples
	//	*TimeSeries_TrendHdrSamples
	Samples isTimeSeries_Samples `protobuf_oneof:"samples"`
	// contains filtered or unexported fields
}

TimeSeries is a single metric with a unique set of labels.

func (*TimeSeries) Descriptor deprecated

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

Deprecated: Use TimeSeries.ProtoReflect.Descriptor instead.

func (*TimeSeries) GetCounterSamples

func (x *TimeSeries) GetCounterSamples() *CounterSamples

func (*TimeSeries) GetGaugeSamples

func (x *TimeSeries) GetGaugeSamples() *GaugeSamples

func (*TimeSeries) GetLabels

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

func (*TimeSeries) GetRateSamples

func (x *TimeSeries) GetRateSamples() *RateSamples

func (*TimeSeries) GetSamples

func (m *TimeSeries) GetSamples() isTimeSeries_Samples

func (*TimeSeries) GetTrendHdrSamples

func (x *TimeSeries) GetTrendHdrSamples() *TrendHdrSamples

func (*TimeSeries) ProtoMessage

func (*TimeSeries) ProtoMessage()

func (*TimeSeries) ProtoReflect

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

func (*TimeSeries) Reset

func (x *TimeSeries) Reset()

func (*TimeSeries) String

func (x *TimeSeries) String() string

type TimeSeries_CounterSamples

type TimeSeries_CounterSamples struct {
	CounterSamples *CounterSamples `protobuf:"bytes,2,opt,name=counter_samples,json=counterSamples,proto3,oneof"`
}

type TimeSeries_GaugeSamples

type TimeSeries_GaugeSamples struct {
	GaugeSamples *GaugeSamples `protobuf:"bytes,3,opt,name=gauge_samples,json=gaugeSamples,proto3,oneof"`
}

type TimeSeries_RateSamples

type TimeSeries_RateSamples struct {
	RateSamples *RateSamples `protobuf:"bytes,4,opt,name=rate_samples,json=rateSamples,proto3,oneof"`
}

type TimeSeries_TrendHdrSamples

type TimeSeries_TrendHdrSamples struct {
	TrendHdrSamples *TrendHdrSamples `protobuf:"bytes,5,opt,name=trend_hdr_samples,json=trendHdrSamples,proto3,oneof"`
}

type TrendHdrSamples

type TrendHdrSamples struct {

	// Required.
	Values []*TrendHdrValue `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
	// contains filtered or unexported fields
}

func (*TrendHdrSamples) Descriptor deprecated

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

Deprecated: Use TrendHdrSamples.ProtoReflect.Descriptor instead.

func (*TrendHdrSamples) GetValues

func (x *TrendHdrSamples) GetValues() []*TrendHdrValue

func (*TrendHdrSamples) ProtoMessage

func (*TrendHdrSamples) ProtoMessage()

func (*TrendHdrSamples) ProtoReflect

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

func (*TrendHdrSamples) Reset

func (x *TrendHdrSamples) Reset()

func (*TrendHdrSamples) String

func (x *TrendHdrSamples) String() string

type TrendHdrValue

type TrendHdrValue struct {

	// Required.
	Time *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
	// positive buckets starting from bucket 1, each counter is an absolute value.
	Counters []uint32      `protobuf:"varint,2,rep,packed,name=counters,proto3" json:"counters,omitempty"`
	Spans    []*BucketSpan `protobuf:"bytes,3,rep,name=spans,proto3" json:"spans,omitempty"`
	// sum of observations
	Sum float64 `protobuf:"fixed64,5,opt,name=sum,proto3" json:"sum,omitempty"`
	// count of observations
	Count uint32 `protobuf:"varint,6,opt,name=count,proto3" json:"count,omitempty"`
	// smallest and largest observed value
	MinValue float64 `protobuf:"fixed64,7,opt,name=min_value,json=minValue,proto3" json:"min_value,omitempty"`
	MaxValue float64 `protobuf:"fixed64,8,opt,name=max_value,json=maxValue,proto3" json:"max_value,omitempty"`
	// counters for zero- and infinity-buckets
	ExtraLowValuesCounter  *uint32 `` /* 135-byte string literal not displayed */
	ExtraHighValuesCounter *uint32 `` /* 139-byte string literal not displayed */
	// min_resolution is a multiplier factor applied to the tracked values of the histogram.
	// It is helpful for up and down scaling values and representing different orders of magnitude.
	// default = 1.0
	MinResolution float64 `protobuf:"fixed64,11,opt,name=min_resolution,json=minResolution,proto3" json:"min_resolution,omitempty"`
	// histogram parameter - number of significant digits used to calculate buckets formula
	// default = 2
	SignificantDigits *uint32 `protobuf:"varint,12,opt,name=significant_digits,json=significantDigits,proto3,oneof" json:"significant_digits,omitempty"`
	// contains filtered or unexported fields
}

func (*TrendHdrValue) Descriptor deprecated

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

Deprecated: Use TrendHdrValue.ProtoReflect.Descriptor instead.

func (*TrendHdrValue) GetCount

func (x *TrendHdrValue) GetCount() uint32

func (*TrendHdrValue) GetCounters

func (x *TrendHdrValue) GetCounters() []uint32

func (*TrendHdrValue) GetExtraHighValuesCounter

func (x *TrendHdrValue) GetExtraHighValuesCounter() uint32

func (*TrendHdrValue) GetExtraLowValuesCounter

func (x *TrendHdrValue) GetExtraLowValuesCounter() uint32

func (*TrendHdrValue) GetMaxValue

func (x *TrendHdrValue) GetMaxValue() float64

func (*TrendHdrValue) GetMinResolution

func (x *TrendHdrValue) GetMinResolution() float64

func (*TrendHdrValue) GetMinValue

func (x *TrendHdrValue) GetMinValue() float64

func (*TrendHdrValue) GetSignificantDigits

func (x *TrendHdrValue) GetSignificantDigits() uint32

func (*TrendHdrValue) GetSpans

func (x *TrendHdrValue) GetSpans() []*BucketSpan

func (*TrendHdrValue) GetSum

func (x *TrendHdrValue) GetSum() float64

func (*TrendHdrValue) GetTime

func (x *TrendHdrValue) GetTime() *timestamppb.Timestamp

func (*TrendHdrValue) ProtoMessage

func (*TrendHdrValue) ProtoMessage()

func (*TrendHdrValue) ProtoReflect

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

func (*TrendHdrValue) Reset

func (x *TrendHdrValue) Reset()

func (*TrendHdrValue) String

func (x *TrendHdrValue) String() string

Jump to

Keyboard shortcuts

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