sources

package
v0.0.0-...-f989eeb Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2015 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CadvisorHosts

type CadvisorHosts struct {
	Port  int               `json:"port"`
	Hosts map[string]string `json:"hosts"`
}

type Container

type Container struct {
	Name  string                     `json:"name,omitempty"`
	Spec  cadvisor.ContainerSpec     `json:"spec,omitempty"`
	Stats []*cadvisor.ContainerStats `json:"stats,omitempty"`
}

type ContainerData

type ContainerData struct {
	Containers []RawContainer
	Machine    []RawContainer
}

type ExternalSource

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

func (*ExternalSource) GetInfo

func (self *ExternalSource) GetInfo() (ContainerData, error)

type RawContainer

type RawContainer struct {
	Hostname string `json:"hostname,omitempty"`
	Container
}

type Source

type Source interface {
	// Fetches containers information from all the nodes in the cluster.
	// Returns:
	// 1. podsOrContainers: A slice of Pod or a slice of RawContainer
	// 2. nodes: A slice of RawContainer, one for each node in the cluster, that contains
	// root cgroup information.
	GetInfo() (ContainerData, error)
}

func NewSource

func NewSource(pollDuration time.Duration) (Source, error)

Jump to

Keyboard shortcuts

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