pinger

package
v0.19.1 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Privileged = true
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	IP                 string
	Interval           time.Duration
	Timeout            time.Duration
	MaxPacketLossCount int
}

type ConnectionStatus

type ConnectionStatus string
const (
	Connected         ConnectionStatus = "connected"
	ConnectionUnknown ConnectionStatus = "unknown"
	ConnectionError   ConnectionStatus = "error"
)

type Interface

type Interface interface {
	Start()
	Stop()
	GetLatencyInfo() *LatencyInfo
	GetIP() string
}

func NewPinger

func NewPinger(config Config) Interface

type LatencyInfo

type LatencyInfo struct {
	ConnectionError  string
	ConnectionStatus ConnectionStatus
	IP               string
	Spec             *submarinerv1.LatencyRTTSpec
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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