Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClusterMonitor ¶
type ClusterMonitor struct { DockerClient *client.Client // contains filtered or unexported fields }
ClusterMonitor is used to collect data from a whole docker host. It may include many clusters
func (*ClusterMonitor) CollectData ¶
func (clm *ClusterMonitor) CollectData() (*data.ClusterStat, error)
CollectData will collect information from docker host
type ContainerMonitor ¶
type ContainerMonitor struct { DaemonURL string // contains filtered or unexported fields }
ContainerMonitor is used to collect data from a docker host
func (*ContainerMonitor) CollectData ¶
func (ctm *ContainerMonitor) CollectData() (*data.ContainerStat, error)
CollectData will collect info for a given container and store into db Will return pointer of the record struct
func (*ContainerMonitor) Init ¶
func (ctm *ContainerMonitor) Init(dockerClient *client.Client, daemonURL, containerID, containerName, outputCol string, outputDB *data.DB) error
Init will finish the setup This should be call first before using any other method
func (*ContainerMonitor) ListContainer ¶
func (ctm *ContainerMonitor) ListContainer() ([]types.Container, error)
ListContainer will get all existing containers on the host @deprecated, just keep for testing
func (*ContainerMonitor) Monit ¶
func (ctm *ContainerMonitor) Monit(dockerClient *client.Client, daemonURL, containerID, containerName, outputCol string, outputDB *data.DB, c chan *data.ContainerStat)
Monit will collect data for a container, exactly return a result pointer to chan
type HostMonitor ¶
type HostMonitor struct {
// contains filtered or unexported fields
}
HostMonitor is used to collect data from a whole docker host. It may include many clusters
func (*HostMonitor) CollectData ¶
func (hm *HostMonitor) CollectData() (*data.HostStat, error)
CollectData will collect information for each cluster at the host