proto

package
v0.10.3 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2019 License: Apache-2.0 Imports: 4 Imported by: 15

Documentation

Index

Constants

View Source
const Default_OutputMetricsOptions_AggregateInCloudprober bool = false
View Source
const Default_ProbeConf_IpVersion int32 = 4
View Source
const Default_ProbeConf_OutputAsMetrics bool = true

Variables

View Source
var OutputMetricsOptions_MetricsKind_name = map[int32]string{
	0: "UNDEFINED",
	1: "GAUGE",
	2: "CUMULATIVE",
}
View Source
var OutputMetricsOptions_MetricsKind_value = map[string]int32{
	"UNDEFINED":  0,
	"GAUGE":      1,
	"CUMULATIVE": 2,
}
View Source
var ProbeConf_Mode_name = map[int32]string{
	0: "ONCE",
	1: "SERVER",
}
View Source
var ProbeConf_Mode_value = map[string]int32{
	"ONCE":   0,
	"SERVER": 1,
}

Functions

This section is empty.

Types

type OutputMetricsOptions

type OutputMetricsOptions struct {
	MetricsKind *OutputMetricsOptions_MetricsKind `` /* 154-byte string literal not displayed */
	// Additional labels (comma-separated) to attach to the output metrics, e.g.
	// "region=us-east1,zone=us-east1-d". ptype="external" and probe="<probeName>"
	// are attached automatically.
	AdditionalLabels *string `protobuf:"bytes,2,opt,name=additional_labels,json=additionalLabels" json:"additional_labels,omitempty"`
	// Whether to aggregate metrics in Cloudprober. If enabled, Cloudprober
	// aggregates the metrics returned by the external probe process -- external
	// probe process should return metrics only since the last probe run.
	// Note that this option is mutually exclusive with GAUGE metrics and
	// cloudprober will fail during initialization if both options are enabled.
	AggregateInCloudprober *bool `` /* 129-byte string literal not displayed */
	// Metrics that should be treated as distributions. These metrics are exported
	// by the external probe program as comma-separated list of values, for
	// example: "op_latency 4.7,5.6,5.9,6.1,4.9". To be able to build distribution
	// from these values, these metrics should be pre-configured in external
	// probe:
	// dist_metric {
	//   key: "op_latency"
	//   value {
	//     explicit_buckets: "1,2,4,8,16,32,64,128,256"
	//   }
	// }
	DistMetric           map[string]*proto1.Dist `` /* 158-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}                `json:"-"`
	XXX_unrecognized     []byte                  `json:"-"`
	XXX_sizecache        int32                   `json:"-"`
}

func (*OutputMetricsOptions) Descriptor

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

func (*OutputMetricsOptions) GetAdditionalLabels

func (m *OutputMetricsOptions) GetAdditionalLabels() string

func (*OutputMetricsOptions) GetAggregateInCloudprober

func (m *OutputMetricsOptions) GetAggregateInCloudprober() bool

func (*OutputMetricsOptions) GetDistMetric

func (m *OutputMetricsOptions) GetDistMetric() map[string]*proto1.Dist

func (*OutputMetricsOptions) GetMetricsKind

func (*OutputMetricsOptions) ProtoMessage

func (*OutputMetricsOptions) ProtoMessage()

func (*OutputMetricsOptions) Reset

func (m *OutputMetricsOptions) Reset()

func (*OutputMetricsOptions) String

func (m *OutputMetricsOptions) String() string

func (*OutputMetricsOptions) XXX_DiscardUnknown

func (m *OutputMetricsOptions) XXX_DiscardUnknown()

func (*OutputMetricsOptions) XXX_Marshal

func (m *OutputMetricsOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*OutputMetricsOptions) XXX_Merge

func (dst *OutputMetricsOptions) XXX_Merge(src proto.Message)

func (*OutputMetricsOptions) XXX_Size

func (m *OutputMetricsOptions) XXX_Size() int

func (*OutputMetricsOptions) XXX_Unmarshal

func (m *OutputMetricsOptions) XXX_Unmarshal(b []byte) error

type OutputMetricsOptions_MetricsKind

type OutputMetricsOptions_MetricsKind int32

MetricsKind specifies whether to treat output metrics as GAUGE or CUMULATIVE. If left unspecified, metrics from ONCE mode probes are treated as GAUGE and metrics from SERVER mode probes are treated as CUMULATIVE.

const (
	OutputMetricsOptions_UNDEFINED  OutputMetricsOptions_MetricsKind = 0
	OutputMetricsOptions_GAUGE      OutputMetricsOptions_MetricsKind = 1
	OutputMetricsOptions_CUMULATIVE OutputMetricsOptions_MetricsKind = 2
)

func (OutputMetricsOptions_MetricsKind) Enum

func (OutputMetricsOptions_MetricsKind) EnumDescriptor

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

func (OutputMetricsOptions_MetricsKind) String

func (*OutputMetricsOptions_MetricsKind) UnmarshalJSON

func (x *OutputMetricsOptions_MetricsKind) UnmarshalJSON(data []byte) error

type ProbeConf

type ProbeConf struct {
	Mode *ProbeConf_Mode `protobuf:"varint,1,opt,name=mode,enum=cloudprober.probes.external.ProbeConf_Mode,def=0" json:"mode,omitempty"`
	// Command.  For ONCE probes, arguments are processed for the following field
	// substitutions:
	// @probe@    Name of the probe
	// @target@   Hostname of the target
	// @address@  IP address of the target
	//
	// For example, for target ig-us-central1-a, /tools/recreate_vm -vm @target@
	// will get converted to: /tools/recreate_vm -vm ig-us-central1-a
	Command *string             `protobuf:"bytes,2,req,name=command" json:"command,omitempty"`
	Options []*ProbeConf_Option `protobuf:"bytes,3,rep,name=options" json:"options,omitempty"`
	// Export output as metrics, where output is the output returned by the
	// external probe process, over stdout for ONCE probes, and through ProbeReply
	// for SERVER probes. Cloudprober expects variables to be in the following
	// format in the output:
	// var1 value1 (for example: total_errors 589)
	OutputAsMetrics      *bool                 `protobuf:"varint,4,opt,name=output_as_metrics,json=outputAsMetrics,def=1" json:"output_as_metrics,omitempty"`
	OutputMetricsOptions *OutputMetricsOptions `protobuf:"bytes,5,opt,name=output_metrics_options,json=outputMetricsOptions" json:"output_metrics_options,omitempty"`
	// IP version: 4|6. For target resolution
	// This field doesn't do anything and will be removed after the release
	// v0.10.3. ip_version can be configured in the outer layer of the config:
	// probe {
	//   type: EXTERNAL
	//   ip_version: 6
	//   external_probe {
	//     ...
	//   }
	// }
	IpVersion            *int32   `protobuf:"varint,100,opt,name=ip_version,json=ipVersion,def=4" json:"ip_version,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ProbeConf) Descriptor

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

func (*ProbeConf) GetCommand

func (m *ProbeConf) GetCommand() string

func (*ProbeConf) GetIpVersion

func (m *ProbeConf) GetIpVersion() int32

func (*ProbeConf) GetMode

func (m *ProbeConf) GetMode() ProbeConf_Mode

func (*ProbeConf) GetOptions

func (m *ProbeConf) GetOptions() []*ProbeConf_Option

func (*ProbeConf) GetOutputAsMetrics

func (m *ProbeConf) GetOutputAsMetrics() bool

func (*ProbeConf) GetOutputMetricsOptions

func (m *ProbeConf) GetOutputMetricsOptions() *OutputMetricsOptions

func (*ProbeConf) ProtoMessage

func (*ProbeConf) ProtoMessage()

func (*ProbeConf) Reset

func (m *ProbeConf) Reset()

func (*ProbeConf) String

func (m *ProbeConf) String() string

func (*ProbeConf) XXX_DiscardUnknown

func (m *ProbeConf) XXX_DiscardUnknown()

func (*ProbeConf) XXX_Marshal

func (m *ProbeConf) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProbeConf) XXX_Merge

func (dst *ProbeConf) XXX_Merge(src proto.Message)

func (*ProbeConf) XXX_Size

func (m *ProbeConf) XXX_Size() int

func (*ProbeConf) XXX_Unmarshal

func (m *ProbeConf) XXX_Unmarshal(b []byte) error

type ProbeConf_Mode

type ProbeConf_Mode int32

External probes support two mode: ONCE and SERVER. In ONCE mode, external command is re-executed for each probe run, while in SERVER mode, command is run in server mode, re-executed only if not running already.

const (
	ProbeConf_ONCE   ProbeConf_Mode = 0
	ProbeConf_SERVER ProbeConf_Mode = 1
)
const Default_ProbeConf_Mode ProbeConf_Mode = ProbeConf_ONCE

func (ProbeConf_Mode) Enum

func (x ProbeConf_Mode) Enum() *ProbeConf_Mode

func (ProbeConf_Mode) EnumDescriptor

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

func (ProbeConf_Mode) String

func (x ProbeConf_Mode) String() string

func (*ProbeConf_Mode) UnmarshalJSON

func (x *ProbeConf_Mode) UnmarshalJSON(data []byte) error

type ProbeConf_Option

type ProbeConf_Option struct {
	Name                 *string  `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
	Value                *string  `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Options for the SERVER mode probe requests. These options are passed on to the external probe server as part of the ProbeRequest. Values are substituted similar to command arguments for the ONCE mode probes.

func (*ProbeConf_Option) Descriptor

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

func (*ProbeConf_Option) GetName

func (m *ProbeConf_Option) GetName() string

func (*ProbeConf_Option) GetValue

func (m *ProbeConf_Option) GetValue() string

func (*ProbeConf_Option) ProtoMessage

func (*ProbeConf_Option) ProtoMessage()

func (*ProbeConf_Option) Reset

func (m *ProbeConf_Option) Reset()

func (*ProbeConf_Option) String

func (m *ProbeConf_Option) String() string

func (*ProbeConf_Option) XXX_DiscardUnknown

func (m *ProbeConf_Option) XXX_DiscardUnknown()

func (*ProbeConf_Option) XXX_Marshal

func (m *ProbeConf_Option) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProbeConf_Option) XXX_Merge

func (dst *ProbeConf_Option) XXX_Merge(src proto.Message)

func (*ProbeConf_Option) XXX_Size

func (m *ProbeConf_Option) XXX_Size() int

func (*ProbeConf_Option) XXX_Unmarshal

func (m *ProbeConf_Option) XXX_Unmarshal(b []byte) error

type ProbeReply

type ProbeReply struct {
	// The sequence number for this request.
	RequestId *int32 `protobuf:"varint,1,req,name=request_id,json=requestId" json:"request_id,omitempty"`
	// For a normal result, this is not present.
	// If it is present, it indicates that the probe failed.
	ErrorMessage *string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage" json:"error_message,omitempty"`
	// The result of the probe. Cloudprober parses the payload to retrieve
	// variables from it. It expects variables in the following format:
	// var1 value1 (for example: total_errors 589)
	// TODO(manugarg): Add an option to export mapped variables, for example:
	// client-errors map:lang java:200 python:20 golang:3
	Payload              *string  `protobuf:"bytes,3,opt,name=payload" json:"payload,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

ProbeReply is the message that external probe server sends back to the cloudprober.

func (*ProbeReply) Descriptor

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

func (*ProbeReply) GetErrorMessage

func (m *ProbeReply) GetErrorMessage() string

func (*ProbeReply) GetPayload

func (m *ProbeReply) GetPayload() string

func (*ProbeReply) GetRequestId

func (m *ProbeReply) GetRequestId() int32

func (*ProbeReply) ProtoMessage

func (*ProbeReply) ProtoMessage()

func (*ProbeReply) Reset

func (m *ProbeReply) Reset()

func (*ProbeReply) String

func (m *ProbeReply) String() string

func (*ProbeReply) XXX_DiscardUnknown

func (m *ProbeReply) XXX_DiscardUnknown()

func (*ProbeReply) XXX_Marshal

func (m *ProbeReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProbeReply) XXX_Merge

func (dst *ProbeReply) XXX_Merge(src proto.Message)

func (*ProbeReply) XXX_Size

func (m *ProbeReply) XXX_Size() int

func (*ProbeReply) XXX_Unmarshal

func (m *ProbeReply) XXX_Unmarshal(b []byte) error

type ProbeRequest

type ProbeRequest struct {
	// The unique identifier for this request.  This is unique across
	// an execution of the probe server.  It starts at 1.
	RequestId *int32 `protobuf:"varint,1,req,name=request_id,json=requestId" json:"request_id,omitempty"`
	// How long to allow for the execution of this request, in
	// milliseconds.  If the time limit is exceeded, the server
	// should abort the request, but *not* send back a reply.  The
	// client will have to do timeouts anyway.
	TimeLimit            *int32                 `protobuf:"varint,2,req,name=time_limit,json=timeLimit" json:"time_limit,omitempty"`
	Options              []*ProbeRequest_Option `protobuf:"bytes,3,rep,name=options" json:"options,omitempty"`
	XXX_NoUnkeyedLiteral struct{}               `json:"-"`
	XXX_unrecognized     []byte                 `json:"-"`
	XXX_sizecache        int32                  `json:"-"`
}

ProbeRequest is the message that cloudprober sends to the external probe server.

func (*ProbeRequest) Descriptor

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

func (*ProbeRequest) GetOptions

func (m *ProbeRequest) GetOptions() []*ProbeRequest_Option

func (*ProbeRequest) GetRequestId

func (m *ProbeRequest) GetRequestId() int32

func (*ProbeRequest) GetTimeLimit

func (m *ProbeRequest) GetTimeLimit() int32

func (*ProbeRequest) ProtoMessage

func (*ProbeRequest) ProtoMessage()

func (*ProbeRequest) Reset

func (m *ProbeRequest) Reset()

func (*ProbeRequest) String

func (m *ProbeRequest) String() string

func (*ProbeRequest) XXX_DiscardUnknown

func (m *ProbeRequest) XXX_DiscardUnknown()

func (*ProbeRequest) XXX_Marshal

func (m *ProbeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProbeRequest) XXX_Merge

func (dst *ProbeRequest) XXX_Merge(src proto.Message)

func (*ProbeRequest) XXX_Size

func (m *ProbeRequest) XXX_Size() int

func (*ProbeRequest) XXX_Unmarshal

func (m *ProbeRequest) XXX_Unmarshal(b []byte) error

type ProbeRequest_Option

type ProbeRequest_Option struct {
	Name                 *string  `protobuf:"bytes,1,req,name=name" json:"name,omitempty"`
	Value                *string  `protobuf:"bytes,2,req,name=value" json:"value,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ProbeRequest_Option) Descriptor

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

func (*ProbeRequest_Option) GetName

func (m *ProbeRequest_Option) GetName() string

func (*ProbeRequest_Option) GetValue

func (m *ProbeRequest_Option) GetValue() string

func (*ProbeRequest_Option) ProtoMessage

func (*ProbeRequest_Option) ProtoMessage()

func (*ProbeRequest_Option) Reset

func (m *ProbeRequest_Option) Reset()

func (*ProbeRequest_Option) String

func (m *ProbeRequest_Option) String() string

func (*ProbeRequest_Option) XXX_DiscardUnknown

func (m *ProbeRequest_Option) XXX_DiscardUnknown()

func (*ProbeRequest_Option) XXX_Marshal

func (m *ProbeRequest_Option) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProbeRequest_Option) XXX_Merge

func (dst *ProbeRequest_Option) XXX_Merge(src proto.Message)

func (*ProbeRequest_Option) XXX_Size

func (m *ProbeRequest_Option) XXX_Size() int

func (*ProbeRequest_Option) XXX_Unmarshal

func (m *ProbeRequest_Option) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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