target

package
v0.0.0-...-8ec60ba Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const MaxConcurrentJobs = 3

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPGet

type HTTPGet struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

HTTPGet Object

func NewHTTPGet

func NewHTTPGet(logger log.Logger, startupDelay time.Duration, name string, url string, srcAddr string, proxy string, interval time.Duration, timeout time.Duration, labels map[string]string) (*HTTPGet, error)

NewHTTPGet starts a new monitoring goroutine

func (*HTTPGet) Compute

func (t *HTTPGet) Compute() *http.HTTPReturn

Compute returns the results of the HTTP metrics

func (*HTTPGet) Labels

func (t *HTTPGet) Labels() map[string]string

Labels returns labels

func (*HTTPGet) Name

func (t *HTTPGet) Name() string

Name returns name

func (*HTTPGet) Stop

func (t *HTTPGet) Stop()

Stop gracefully stops the monitoring

func (*HTTPGet) URL

func (t *HTTPGet) URL() string

URL returns host

type MTR

type MTR struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

MTR Object

func NewMTR

func NewMTR(logger log.Logger, icmpID *common.IcmpID, startupDelay time.Duration, name string, host string, srcAddr string, interval time.Duration, timeout time.Duration, maxHops int, count int, labels map[string]string) (*MTR, error)

NewMTR starts a new monitoring goroutine

func (*MTR) Compute

func (t *MTR) Compute() *mtr.MtrResult

Compute returns the results of the MTR metrics

func (*MTR) Host

func (t *MTR) Host() string

Host returns host

func (*MTR) Labels

func (t *MTR) Labels() map[string]string

Labels returns labels

func (*MTR) Name

func (t *MTR) Name() string

Name returns name

func (*MTR) Stop

func (t *MTR) Stop()

Stop gracefully stops the monitoring

type PING

type PING struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

PING Object

func NewPing

func NewPing(logger log.Logger, icmpID *common.IcmpID, startupDelay time.Duration, name string, host string, ip string, srcAddr string, interval time.Duration, timeout time.Duration, count int, labels map[string]string) (*PING, error)

NewPing starts a new monitoring goroutine

func (*PING) Compute

func (t *PING) Compute() *ping.PingResult

Compute returns the results of the Ping metrics

func (*PING) Host

func (t *PING) Host() string

Host returns host

func (*PING) Ip

func (t *PING) Ip() string

Ip returns ip

func (*PING) Labels

func (t *PING) Labels() map[string]string

Labels returns labels

func (*PING) Name

func (t *PING) Name() string

Name returns name

func (*PING) Stop

func (t *PING) Stop()

Stop gracefully stops the monitoring

type TCPPort

type TCPPort struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

TCPPort Object

func NewTCPPort

func NewTCPPort(logger log.Logger, startupDelay time.Duration, name string, host string, ip string, srcAddr string, port string, interval time.Duration, timeout time.Duration, labels map[string]string) (*TCPPort, error)

NewTCPPort starts a new monitoring goroutine

func (*TCPPort) Compute

func (t *TCPPort) Compute() *tcp.TCPPortReturn

Compute returns the results of the TCP metrics

func (*TCPPort) Host

func (t *TCPPort) Host() string

Host returns host

func (*TCPPort) Ip

func (t *TCPPort) Ip() string

Ip returns ip

func (*TCPPort) Labels

func (t *TCPPort) Labels() map[string]string

Labels returns labels

func (*TCPPort) Name

func (t *TCPPort) Name() string

Name returns name

func (*TCPPort) Stop

func (t *TCPPort) Stop()

Stop gracefully stops the monitoring

Jump to

Keyboard shortcuts

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