Documentation ¶
Overview ¶
Package metricspb is a generated protocol buffer package.
It is generated from these files:
github.com/lightstep/lightstep-tracer-common/tmpgen/metrics.proto
It has these top-level messages:
MetricPoint IngestRequest IngestResponse
Index ¶
- Variables
- func RegisterMetricsServiceServer(s *grpc.Server, srv MetricsServiceServer)
- type IngestRequest
- func (*IngestRequest) Descriptor() ([]byte, []int)
- func (m *IngestRequest) GetIdempotencyKey() string
- func (m *IngestRequest) GetPoints() []*MetricPoint
- func (m *IngestRequest) GetReporter() *lightstep_collector.Reporter
- func (m *IngestRequest) Marshal() (dAtA []byte, err error)
- func (m *IngestRequest) MarshalTo(dAtA []byte) (int, error)
- func (*IngestRequest) ProtoMessage()
- func (m *IngestRequest) Reset()
- func (m *IngestRequest) Size() (n int)
- func (m *IngestRequest) String() string
- func (m *IngestRequest) Unmarshal(dAtA []byte) error
- type IngestResponse
- func (*IngestResponse) Descriptor() ([]byte, []int)
- func (m *IngestResponse) Marshal() (dAtA []byte, err error)
- func (m *IngestResponse) MarshalTo(dAtA []byte) (int, error)
- func (*IngestResponse) ProtoMessage()
- func (m *IngestResponse) Reset()
- func (m *IngestResponse) Size() (n int)
- func (m *IngestResponse) String() string
- func (m *IngestResponse) Unmarshal(dAtA []byte) error
- type MetricKind
- type MetricPoint
- func (*MetricPoint) Descriptor() ([]byte, []int)
- func (m *MetricPoint) GetDoubleValue() float64
- func (m *MetricPoint) GetDuration() *google_protobuf2.Duration
- func (m *MetricPoint) GetKind() MetricKind
- func (m *MetricPoint) GetLabels() []*lightstep_collector.KeyValue
- func (m *MetricPoint) GetMetricName() string
- func (m *MetricPoint) GetStart() *google_protobuf.Timestamp
- func (m *MetricPoint) GetUint64Value() uint64
- func (m *MetricPoint) GetValue() isMetricPoint_Value
- func (m *MetricPoint) Marshal() (dAtA []byte, err error)
- func (m *MetricPoint) MarshalTo(dAtA []byte) (int, error)
- func (*MetricPoint) ProtoMessage()
- func (m *MetricPoint) Reset()
- func (m *MetricPoint) Size() (n int)
- func (m *MetricPoint) String() string
- func (m *MetricPoint) Unmarshal(dAtA []byte) error
- func (*MetricPoint) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, ...)
- type MetricPoint_DoubleValue
- type MetricPoint_Uint64Value
- type MetricsServiceClient
- type MetricsServiceServer
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidLengthMetrics = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowMetrics = fmt.Errorf("proto: integer overflow") )
View Source
var MetricKind_name = map[int32]string{
0: "INVALID_METRIC_KIND",
1: "COUNTER",
2: "GAUGE",
}
View Source
var MetricKind_value = map[string]int32{
"INVALID_METRIC_KIND": 0,
"COUNTER": 1,
"GAUGE": 2,
}
Functions ¶
func RegisterMetricsServiceServer ¶
func RegisterMetricsServiceServer(s *grpc.Server, srv MetricsServiceServer)
Types ¶
type IngestRequest ¶
type IngestRequest struct { // IdempotencyKey is a random string that should uniquely identify this report. // It should be generated once and used for all retries. The server will use it // to de-duplicate requests. IdempotencyKey string `protobuf:"bytes,1,opt,name=idempotency_key,json=idempotencyKey,proto3" json:"idempotency_key,omitempty"` // Reporter contains information to identify the specific originator of this report. Reporter *lightstep_collector.Reporter `protobuf:"bytes,2,opt,name=reporter" json:"reporter,omitempty"` // Points contain the individual updates. Points []*MetricPoint `protobuf:"bytes,3,rep,name=points" json:"points,omitempty"` }
IngestRequest is an update to one or more measures.
func (*IngestRequest) Descriptor ¶
func (*IngestRequest) Descriptor() ([]byte, []int)
func (*IngestRequest) GetIdempotencyKey ¶
func (m *IngestRequest) GetIdempotencyKey() string
func (*IngestRequest) GetPoints ¶
func (m *IngestRequest) GetPoints() []*MetricPoint
func (*IngestRequest) GetReporter ¶
func (m *IngestRequest) GetReporter() *lightstep_collector.Reporter
func (*IngestRequest) Marshal ¶
func (m *IngestRequest) Marshal() (dAtA []byte, err error)
func (*IngestRequest) ProtoMessage ¶
func (*IngestRequest) ProtoMessage()
func (*IngestRequest) Reset ¶
func (m *IngestRequest) Reset()
func (*IngestRequest) Size ¶
func (m *IngestRequest) Size() (n int)
func (*IngestRequest) String ¶
func (m *IngestRequest) String() string
func (*IngestRequest) Unmarshal ¶
func (m *IngestRequest) Unmarshal(dAtA []byte) error
type IngestResponse ¶
type IngestResponse struct { }
IngestResponse is reserved for future use.
func (*IngestResponse) Descriptor ¶
func (*IngestResponse) Descriptor() ([]byte, []int)
func (*IngestResponse) Marshal ¶
func (m *IngestResponse) Marshal() (dAtA []byte, err error)
func (*IngestResponse) ProtoMessage ¶
func (*IngestResponse) ProtoMessage()
func (*IngestResponse) Reset ¶
func (m *IngestResponse) Reset()
func (*IngestResponse) Size ¶
func (m *IngestResponse) Size() (n int)
func (*IngestResponse) String ¶
func (m *IngestResponse) String() string
func (*IngestResponse) Unmarshal ¶
func (m *IngestResponse) Unmarshal(dAtA []byte) error
type MetricKind ¶
type MetricKind int32
MetricKind indicates the semantics of the points (i.e. how to interpret values relative to each other).
const ( // InvalidMetricKind is the default value for the MetricKind. Some languages' proto compilers // (e.g. Go) return the default if no value is set. The default is marked invalid here to // avoid a common mistake where a field is left unset and appears to be set to the default. MetricKind_INVALID_METRIC_KIND MetricKind = 0 // Counter metrics measure change over an interval. // When aggregated, counter metrics are usually added. MetricKind_COUNTER MetricKind = 1 // Gauge metrics measure the value at a point in time. // When aggregated, intermediate values are often dropped for the latest value. MetricKind_GAUGE MetricKind = 2 )
func (MetricKind) EnumDescriptor ¶
func (MetricKind) EnumDescriptor() ([]byte, []int)
func (MetricKind) String ¶
func (x MetricKind) String() string
type MetricPoint ¶
type MetricPoint struct { // Kind indicates the semantics of this point. Kind should always be the same for a given metric // name (e.g. "cpu.usage" should always have the same kind) Kind MetricKind `protobuf:"varint,1,opt,name=kind,proto3,enum=lightstep.metrics.MetricKind" json:"kind,omitempty"` // MetricName indicates the metric being emitted. MetricName string `protobuf:"bytes,2,opt,name=metric_name,json=metricName,proto3" json:"metric_name,omitempty"` // Start of the interval for which the points represent. // - All Counter points will be assumed to represent the entire interval. // - All Gauge points will be assumed to be instantaneous at the start of the interval. Start *google_protobuf.Timestamp `protobuf:"bytes,3,opt,name=start" json:"start,omitempty"` // Duration of the interval for which the points represent. The end of the interval is start + duration. // We expect this value to be unset or zero for Gauge points. Duration *google_protobuf2.Duration `protobuf:"bytes,4,opt,name=duration" json:"duration,omitempty"` // Labels contain labels specific to this point. Labels []*lightstep_collector.KeyValue `protobuf:"bytes,5,rep,name=labels" json:"labels,omitempty"` // Value represents the update being emitted. Values can be one of two types: uint64 or double. // The type of the value should always be the same for a given metric name (e.g. "cpu.usage" // should always have value type double). // // Types that are valid to be assigned to Value: // *MetricPoint_Uint64Value // *MetricPoint_DoubleValue Value isMetricPoint_Value `protobuf_oneof:"value"` }
MetricPoint is an update to a single measure.
func (*MetricPoint) Descriptor ¶
func (*MetricPoint) Descriptor() ([]byte, []int)
func (*MetricPoint) GetDoubleValue ¶
func (m *MetricPoint) GetDoubleValue() float64
func (*MetricPoint) GetDuration ¶
func (m *MetricPoint) GetDuration() *google_protobuf2.Duration
func (*MetricPoint) GetKind ¶
func (m *MetricPoint) GetKind() MetricKind
func (*MetricPoint) GetLabels ¶
func (m *MetricPoint) GetLabels() []*lightstep_collector.KeyValue
func (*MetricPoint) GetMetricName ¶
func (m *MetricPoint) GetMetricName() string
func (*MetricPoint) GetStart ¶
func (m *MetricPoint) GetStart() *google_protobuf.Timestamp
func (*MetricPoint) GetUint64Value ¶
func (m *MetricPoint) GetUint64Value() uint64
func (*MetricPoint) GetValue ¶
func (m *MetricPoint) GetValue() isMetricPoint_Value
func (*MetricPoint) Marshal ¶
func (m *MetricPoint) Marshal() (dAtA []byte, err error)
func (*MetricPoint) ProtoMessage ¶
func (*MetricPoint) ProtoMessage()
func (*MetricPoint) Reset ¶
func (m *MetricPoint) Reset()
func (*MetricPoint) Size ¶
func (m *MetricPoint) Size() (n int)
func (*MetricPoint) String ¶
func (m *MetricPoint) String() string
func (*MetricPoint) Unmarshal ¶
func (m *MetricPoint) Unmarshal(dAtA []byte) error
func (*MetricPoint) XXX_OneofFuncs ¶
func (*MetricPoint) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})
XXX_OneofFuncs is for the internal use of the proto package.
type MetricPoint_DoubleValue ¶
type MetricPoint_DoubleValue struct {
DoubleValue float64 `protobuf:"fixed64,7,opt,name=double_value,json=doubleValue,proto3,oneof"`
}
func (*MetricPoint_DoubleValue) MarshalTo ¶
func (m *MetricPoint_DoubleValue) MarshalTo(dAtA []byte) (int, error)
func (*MetricPoint_DoubleValue) Size ¶
func (m *MetricPoint_DoubleValue) Size() (n int)
type MetricPoint_Uint64Value ¶
type MetricPoint_Uint64Value struct {
Uint64Value uint64 `protobuf:"varint,6,opt,name=uint64_value,json=uint64Value,proto3,oneof"`
}
func (*MetricPoint_Uint64Value) MarshalTo ¶
func (m *MetricPoint_Uint64Value) MarshalTo(dAtA []byte) (int, error)
func (*MetricPoint_Uint64Value) Size ¶
func (m *MetricPoint_Uint64Value) Size() (n int)
type MetricsServiceClient ¶
type MetricsServiceClient interface {
Report(ctx context.Context, in *IngestRequest, opts ...grpc.CallOption) (*IngestResponse, error)
}
func NewMetricsServiceClient ¶
func NewMetricsServiceClient(cc *grpc.ClientConn) MetricsServiceClient
type MetricsServiceServer ¶
type MetricsServiceServer interface {
Report(context.Context, *IngestRequest) (*IngestResponse, error)
}
Click to show internal directories.
Click to hide internal directories.