http

package
v0.0.0-...-eff70b3 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2018 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package http is a generated protocol buffer package.

It is generated from these files:

github.com/google/cloudprober/probes/http/config.proto

It has these top-level messages:

ProbeConf

Package http implements HTTP probe type.

Index

Constants

View Source
const Default_ProbeConf_ExportResponseAsMetrics bool = false
View Source
const Default_ProbeConf_RequestsIntervalMsec int32 = 25
View Source
const Default_ProbeConf_RequestsPerProbe int32 = 1
View Source
const Default_ProbeConf_ResolveFirst bool = false
View Source
const Default_ProbeConf_StatsExportIntervalMsec int32 = 10000

Variables

View Source
var ProbeConf_ProtocolType_name = map[int32]string{
	0: "HTTP",
	1: "HTTPS",
}
View Source
var ProbeConf_ProtocolType_value = map[string]int32{
	"HTTP":  0,
	"HTTPS": 1,
}

Functions

This section is empty.

Types

type Probe

type Probe struct {
	// contains filtered or unexported fields
}

Probe holds aggregate information about all probe runs, per-target.

func (*Probe) Init

func (p *Probe) Init(name string, opts *options.Options) error

Init initializes the probe with the given params.

func (*Probe) Start

func (p *Probe) Start(ctx context.Context, dataChan chan *metrics.EventMetrics)

Start starts and runs the probe indefinitely.

type ProbeConf

type ProbeConf struct {
	// Which HTTP protocol to use
	Protocol *ProbeConf_ProtocolType `protobuf:"varint,1,opt,name=protocol,enum=cloudprober.probes.http.ProbeConf_ProtocolType,def=0" json:"protocol,omitempty"`
	// Relative URL (to append to all targets). Must begin with '/'
	RelativeUrl *string `protobuf:"bytes,2,opt,name=relative_url,json=relativeUrl" json:"relative_url,omitempty"`
	// Port, default is 80 for HTTP and 443 for HTTPS
	Port *int32 `protobuf:"varint,3,opt,name=port" json:"port,omitempty"`
	// Whether to resolve the target before making the request. If set to false,
	// we hand over the target and relative_url directly to the golang's HTTP
	// module, Otherwise, we resolve the target first to an IP address and
	// make a request using that while passing target name as Host header.
	ResolveFirst *bool `protobuf:"varint,4,opt,name=resolve_first,json=resolveFirst,def=0" json:"resolve_first,omitempty"`
	// Export response (body) count as a metric
	ExportResponseAsMetrics *bool `` /* 134-byte string literal not displayed */
	// Requests per probe
	RequestsPerProbe *int32 `protobuf:"varint,98,opt,name=requests_per_probe,json=requestsPerProbe,def=1" json:"requests_per_probe,omitempty"`
	// How long to wait between two requests to the same target
	RequestsIntervalMsec *int32 `protobuf:"varint,99,opt,name=requests_interval_msec,json=requestsIntervalMsec,def=25" json:"requests_interval_msec,omitempty"`
	// Export stats after these many milliseconds
	StatsExportIntervalMsec *int32 `` /* 140-byte string literal not displayed */
	XXX_unrecognized        []byte `json:"-"`
}

func (*ProbeConf) Descriptor

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

func (*ProbeConf) GetExportResponseAsMetrics

func (m *ProbeConf) GetExportResponseAsMetrics() bool

func (*ProbeConf) GetPort

func (m *ProbeConf) GetPort() int32

func (*ProbeConf) GetProtocol

func (m *ProbeConf) GetProtocol() ProbeConf_ProtocolType

func (*ProbeConf) GetRelativeUrl

func (m *ProbeConf) GetRelativeUrl() string

func (*ProbeConf) GetRequestsIntervalMsec

func (m *ProbeConf) GetRequestsIntervalMsec() int32

func (*ProbeConf) GetRequestsPerProbe

func (m *ProbeConf) GetRequestsPerProbe() int32

func (*ProbeConf) GetResolveFirst

func (m *ProbeConf) GetResolveFirst() bool

func (*ProbeConf) GetStatsExportIntervalMsec

func (m *ProbeConf) GetStatsExportIntervalMsec() int32

func (*ProbeConf) ProtoMessage

func (*ProbeConf) ProtoMessage()

func (*ProbeConf) Reset

func (m *ProbeConf) Reset()

func (*ProbeConf) String

func (m *ProbeConf) String() string

type ProbeConf_ProtocolType

type ProbeConf_ProtocolType int32
const (
	ProbeConf_HTTP  ProbeConf_ProtocolType = 0
	ProbeConf_HTTPS ProbeConf_ProtocolType = 1
)
const Default_ProbeConf_Protocol ProbeConf_ProtocolType = ProbeConf_HTTP

func (ProbeConf_ProtocolType) Enum

func (ProbeConf_ProtocolType) EnumDescriptor

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

func (ProbeConf_ProtocolType) String

func (x ProbeConf_ProtocolType) String() string

func (*ProbeConf_ProtocolType) UnmarshalJSON

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

Directories

Path Synopsis
This program implements a stand-alone http prober binary using the cloudprober/http package.
This program implements a stand-alone http prober binary using the cloudprober/http package.

Jump to

Keyboard shortcuts

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