client

package
v0.0.0-...-52bbffb Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2020 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	APIV1 = "v1"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	GetPodsCPURequests(namespace string) (MetricsList, error)
	GetPodsMemoryRequests(namespace string) (MetricsList, error)
	GetPodsMemoryUsage(namespace string) (MetricsList, error)
	GetPodsCPUUsage(namespace string) (MetricsList, error)
}

func New

func New(config ClientConfig) (Client, error)

type ClientConfig

type ClientConfig struct {
	Endpoint string
	Version  string
	Timeout  time.Duration
}

type MetricsList

type MetricsList []*models.PodMetric

type V1Client

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

func NewV1Client

func NewV1Client(config ClientConfig) (*V1Client, error)

func (*V1Client) GetPodsCPURequests

func (client *V1Client) GetPodsCPURequests(namespace string) (MetricsList, error)

func (*V1Client) GetPodsCPUUsage

func (client *V1Client) GetPodsCPUUsage(namespace string) (MetricsList, error)

func (*V1Client) GetPodsMemoryRequests

func (client *V1Client) GetPodsMemoryRequests(namespace string) (MetricsList, error)

func (*V1Client) GetPodsMemoryUsage

func (client *V1Client) GetPodsMemoryUsage(namespace string) (MetricsList, error)

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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