statscollector

package
v0.0.0-...-a11b7ec Latest Latest
Warning

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

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

Documentation

Overview

Package statscollector implements plugin that collects the statistics from vpp interfaces and publishes them to prometheus.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Deps

type Deps struct {
	local.PluginInfraDeps

	// Contiv plugin is used to lookup pod related to interfaces statistics
	Contiv contiv.API

	// Prometheus plugin used to stream statistics
	Prometheus prometheusplugin.API
}

Deps groups the dependencies of the Plugin.

type Plugin

type Plugin struct {
	Deps
	sync.Mutex
	// contains filtered or unexported fields
}

Plugin collects the statistics from vpp interfaces and publishes them to prometheus.

func (*Plugin) AfterInit

func (p *Plugin) AfterInit() error

AfterInit subscribes for monitoring of changes in ContainerIndex

func (*Plugin) Close

func (p *Plugin) Close() error

Close cleans up the plugin resources

func (*Plugin) Init

func (p *Plugin) Init() error

Init initializes the plugin resources

func (*Plugin) PrintStats

func (p *Plugin) PrintStats()

PrintStats periodically dumps stats to log

func (*Plugin) Put

func (p *Plugin) Put(key string, data proto.Message, opts ...datasync.PutOption) error

Put updates the statistics for the given key

Jump to

Keyboard shortcuts

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