pb

package
v1.1.14 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	KeyType_name = map[int32]string{
		0: "X",
		1: "I",
		2: "U",
		3: "F",
		4: "B",
		5: "D",
		6: "NIL",
		7: "S",
		8: "A",
	}
	KeyType_value = map[string]int32{
		"X":   0,
		"I":   1,
		"U":   2,
		"F":   3,
		"B":   4,
		"D":   5,
		"NIL": 6,
		"S":   7,
		"A":   8,
	}
)

Enum value maps for KeyType.

View Source
var (
	MetricType_name = map[int32]string{
		0: "UNSPECIFIED",
		1: "COUNT",
		2: "RATE",
		3: "GAUGE",
	}
	MetricType_value = map[string]int32{
		"UNSPECIFIED": 0,
		"COUNT":       1,
		"RATE":        2,
		"GAUGE":       3,
	}
)

Enum value maps for MetricType.

View Source
var File_point_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type AnyDemo

type AnyDemo struct {
	Demo string `protobuf:"bytes,1,opt,name=demo,proto3" json:"demo,omitempty"`
	// contains filtered or unexported fields
}

example of pb.Any

func (*AnyDemo) Descriptor deprecated

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

Deprecated: Use AnyDemo.ProtoReflect.Descriptor instead.

func (*AnyDemo) GetDemo

func (x *AnyDemo) GetDemo() string

func (*AnyDemo) ProtoMessage

func (*AnyDemo) ProtoMessage()

func (*AnyDemo) ProtoReflect

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

func (*AnyDemo) Reset

func (x *AnyDemo) Reset()

func (*AnyDemo) String

func (x *AnyDemo) String() string

type Array

type Array struct {
	Arr []*BasicTypes `protobuf:"bytes,1,rep,name=arr,proto3" json:"arr,omitempty"`
	// contains filtered or unexported fields
}

func (*Array) Descriptor deprecated

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

Deprecated: Use Array.ProtoReflect.Descriptor instead.

func (*Array) GetArr

func (x *Array) GetArr() []*BasicTypes

func (*Array) ProtoMessage

func (*Array) ProtoMessage()

func (*Array) ProtoReflect

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

func (*Array) Reset

func (x *Array) Reset()

func (*Array) String

func (x *Array) String() string

type BasicTypes

type BasicTypes struct {

	// Types that are assignable to X:
	//	*BasicTypes_I
	//	*BasicTypes_U
	//	*BasicTypes_F
	//	*BasicTypes_B
	//	*BasicTypes_D
	//	*BasicTypes_S
	X isBasicTypes_X `protobuf_oneof:"x"`
	// contains filtered or unexported fields
}

func (*BasicTypes) Descriptor deprecated

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

Deprecated: Use BasicTypes.ProtoReflect.Descriptor instead.

func (*BasicTypes) GetB

func (x *BasicTypes) GetB() bool

func (*BasicTypes) GetD

func (x *BasicTypes) GetD() []byte

func (*BasicTypes) GetF

func (x *BasicTypes) GetF() float64

func (*BasicTypes) GetI

func (x *BasicTypes) GetI() int64

func (*BasicTypes) GetS

func (x *BasicTypes) GetS() string

func (*BasicTypes) GetU

func (x *BasicTypes) GetU() uint64

func (*BasicTypes) GetX

func (m *BasicTypes) GetX() isBasicTypes_X

func (*BasicTypes) ProtoMessage

func (*BasicTypes) ProtoMessage()

func (*BasicTypes) ProtoReflect

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

func (*BasicTypes) Reset

func (x *BasicTypes) Reset()

func (*BasicTypes) String

func (x *BasicTypes) String() string

type BasicTypes_B

type BasicTypes_B struct {
	B bool `protobuf:"varint,4,opt,name=b,proto3,oneof"` // bool
}

type BasicTypes_D

type BasicTypes_D struct {
	D []byte `protobuf:"bytes,5,opt,name=d,proto3,oneof"` // bytes, for binary data
}

type BasicTypes_F

type BasicTypes_F struct {
	F float64 `protobuf:"fixed64,3,opt,name=f,proto3,oneof"` // float64
}

type BasicTypes_I

type BasicTypes_I struct {
	I int64 `protobuf:"varint,1,opt,name=i,proto3,oneof"` // signed int
}

type BasicTypes_S

type BasicTypes_S struct {
	S string `protobuf:"bytes,6,opt,name=s,proto3,oneof"` // string, for string data
}

type BasicTypes_U

type BasicTypes_U struct {
	U uint64 `protobuf:"varint,2,opt,name=u,proto3,oneof"` // unsigned int
}

type Debug

type Debug struct {
	Info string `protobuf:"bytes,1,opt,name=info,proto3" json:"info,omitempty"`
	// contains filtered or unexported fields
}

Debug used to attached some debug info for the point, these debug info will encoded into payload, storage can take optional handle on these debug info.

func (*Debug) Descriptor deprecated

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

Deprecated: Use Debug.ProtoReflect.Descriptor instead.

func (*Debug) GetInfo

func (x *Debug) GetInfo() string

func (*Debug) ProtoMessage

func (*Debug) ProtoMessage()

func (*Debug) ProtoReflect

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

func (*Debug) Reset

func (x *Debug) Reset()

func (*Debug) String

func (x *Debug) String() string

type Field

type Field struct {
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` // field name
	// See https://developers.google.com/protocol-buffers/docs/proto3#json
	//
	// Types that are assignable to Val:
	//	*Field_I
	//	*Field_U
	//	*Field_F
	//	*Field_B
	//	*Field_D
	//	*Field_S
	//	*Field_A
	Val   isField_Val `protobuf_oneof:"val"`
	IsTag bool        `protobuf:"varint,8,opt,name=is_tag,proto3" json:"is_tag,omitempty"` // set field as a tag or not
	Type  MetricType  `protobuf:"varint,9,opt,name=type,proto3,enum=pb.MetricType" json:"type,omitempty"`
	// field unit name
	Unit string `protobuf:"bytes,10,opt,name=unit,proto3" json:"unit,omitempty"` // metric unit, such as bytes(B), duration(ms/us) and so on.
	// contains filtered or unexported fields
}

func (*Field) Descriptor deprecated

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

Deprecated: Use Field.ProtoReflect.Descriptor instead.

func (*Field) GetA

func (x *Field) GetA() *anypb.Any

func (*Field) GetB

func (x *Field) GetB() bool

func (*Field) GetD

func (x *Field) GetD() []byte

func (*Field) GetF

func (x *Field) GetF() float64

func (*Field) GetI

func (x *Field) GetI() int64

func (*Field) GetIsTag

func (x *Field) GetIsTag() bool

func (*Field) GetKey

func (x *Field) GetKey() string

func (*Field) GetS

func (x *Field) GetS() string

func (*Field) GetType

func (x *Field) GetType() MetricType

func (*Field) GetU

func (x *Field) GetU() uint64

func (*Field) GetUnit

func (x *Field) GetUnit() string

func (*Field) GetVal

func (m *Field) GetVal() isField_Val

func (*Field) ProtoMessage

func (*Field) ProtoMessage()

func (*Field) ProtoReflect

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

func (*Field) Reset

func (x *Field) Reset()

func (*Field) String

func (x *Field) String() string

type Field_A

type Field_A struct {
	// XXX: not used
	A *anypb.Any `protobuf:"bytes,7,opt,name=a,proto3,oneof"` // any data
}

type Field_B

type Field_B struct {
	B bool `protobuf:"varint,5,opt,name=b,proto3,oneof"` // bool
}

type Field_D

type Field_D struct {
	D []byte `protobuf:"bytes,6,opt,name=d,proto3,oneof"` // bytes, for binary data
}

type Field_F

type Field_F struct {
	F float64 `protobuf:"fixed64,4,opt,name=f,proto3,oneof"` // float64
}

type Field_I

type Field_I struct {
	I int64 `protobuf:"varint,2,opt,name=i,proto3,oneof"` // signed int
}

type Field_S

type Field_S struct {
	S string `protobuf:"bytes,11,opt,name=s,proto3,oneof"` // string, for string data
}

type Field_U

type Field_U struct {
	U uint64 `protobuf:"varint,3,opt,name=u,proto3,oneof"` // unsigned int
}

type KeyType

type KeyType int32
const (
	KeyType_X   KeyType = 0 // unknown
	KeyType_I   KeyType = 1
	KeyType_U   KeyType = 2
	KeyType_F   KeyType = 3
	KeyType_B   KeyType = 4
	KeyType_D   KeyType = 5
	KeyType_NIL KeyType = 6
	KeyType_S   KeyType = 7
	KeyType_A   KeyType = 8
)

func (KeyType) Descriptor

func (KeyType) Descriptor() protoreflect.EnumDescriptor

func (KeyType) Enum

func (x KeyType) Enum() *KeyType

func (KeyType) EnumDescriptor deprecated

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

Deprecated: Use KeyType.Descriptor instead.

func (KeyType) Number

func (x KeyType) Number() protoreflect.EnumNumber

func (KeyType) String

func (x KeyType) String() string

func (KeyType) Type

func (KeyType) Type() protoreflect.EnumType

type Map

type Map struct {
	Map map[string]*BasicTypes `` /* 147-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*Map) Descriptor deprecated

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

Deprecated: Use Map.ProtoReflect.Descriptor instead.

func (*Map) GetMap

func (x *Map) GetMap() map[string]*BasicTypes

func (*Map) ProtoMessage

func (*Map) ProtoMessage()

func (*Map) ProtoReflect

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

func (*Map) Reset

func (x *Map) Reset()

func (*Map) String

func (x *Map) String() string

type MetricType

type MetricType int32
const (
	MetricType_UNSPECIFIED MetricType = 0
	MetricType_COUNT       MetricType = 1
	MetricType_RATE        MetricType = 2
	MetricType_GAUGE       MetricType = 3
)

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 PBPoint

type PBPoint struct {
	Name   string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Fields []*Field `protobuf:"bytes,2,rep,name=fields,proto3" json:"fields,omitempty"`
	Time   int64    `protobuf:"varint,3,opt,name=time,proto3" json:"time,omitempty"`
	// Auxiliary fields for the point, they should not
	// write to the final storage on production.
	Warns  []*Warn  `protobuf:"bytes,4,rep,name=warns,proto3" json:"warns,omitempty"`
	Debugs []*Debug `protobuf:"bytes,5,rep,name=debugs,proto3" json:"debugs,omitempty"`
	// contains filtered or unexported fields
}

func (*PBPoint) Descriptor deprecated

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

Deprecated: Use PBPoint.ProtoReflect.Descriptor instead.

func (*PBPoint) GetDebugs

func (x *PBPoint) GetDebugs() []*Debug

func (*PBPoint) GetFields

func (x *PBPoint) GetFields() []*Field

func (*PBPoint) GetName

func (x *PBPoint) GetName() string

func (*PBPoint) GetTime

func (x *PBPoint) GetTime() int64

func (*PBPoint) GetWarns

func (x *PBPoint) GetWarns() []*Warn

func (*PBPoint) ProtoMessage

func (*PBPoint) ProtoMessage()

func (*PBPoint) ProtoReflect

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

func (*PBPoint) Reset

func (x *PBPoint) Reset()

func (*PBPoint) String

func (x *PBPoint) String() string

type PBPoints

type PBPoints struct {
	Arr []*PBPoint `protobuf:"bytes,1,rep,name=arr,proto3" json:"arr,omitempty"`
	// contains filtered or unexported fields
}

batch of pbpoint.

func (*PBPoints) Descriptor deprecated

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

Deprecated: Use PBPoints.ProtoReflect.Descriptor instead.

func (*PBPoints) GetArr

func (x *PBPoints) GetArr() []*PBPoint

func (*PBPoints) ProtoMessage

func (*PBPoints) ProtoMessage()

func (*PBPoints) ProtoReflect

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

func (*PBPoints) Reset

func (x *PBPoints) Reset()

func (*PBPoints) String

func (x *PBPoints) String() string

type Warn

type Warn struct {
	Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=msg,json=message,proto3" json:"msg,omitempty"`
	// contains filtered or unexported fields
}

Warn used to attach some warning message during building the point.

func (*Warn) Descriptor deprecated

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

Deprecated: Use Warn.ProtoReflect.Descriptor instead.

func (*Warn) GetMsg

func (x *Warn) GetMsg() string

func (*Warn) GetType

func (x *Warn) GetType() string

func (*Warn) ProtoMessage

func (*Warn) ProtoMessage()

func (*Warn) ProtoReflect

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

func (*Warn) Reset

func (x *Warn) Reset()

func (*Warn) String

func (x *Warn) String() string

Jump to

Keyboard shortcuts

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