testing

package
v1.11.0 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const CollectorName = "FakeLocalCollector"

Variables

This section is empty.

Functions

func NewFakeLocalCollector

func NewFakeLocalCollector(config *config.Configuration, cgroupManager cgroup.CgroupManager) framework.MetricCollect

Types

type FakeLocalCollector

type FakeLocalCollector struct {
	CgroupManager          cgroup.CgroupManager
	InitiatedSubCollectors map[string]local.SubCollector
}

func (*FakeLocalCollector) CollectMetrics

func (f *FakeLocalCollector) CollectMetrics(metricInfo interface{}, start time.Time, window metav1.Duration) ([]*prompb.TimeSeries, error)

func (*FakeLocalCollector) MetricCollectorName

func (f *FakeLocalCollector) MetricCollectorName() string

func (*FakeLocalCollector) Run

func (f *FakeLocalCollector) Run() error

type FakeSubCollectorCPU

type FakeSubCollectorCPU struct {
}

func (*FakeSubCollectorCPU) CollectLocalMetrics

func (s *FakeSubCollectorCPU) CollectLocalMetrics(metricInfo *local.LocalMetricInfo, start time.Time, window metav1.Duration) ([]*prompb.TimeSeries, error)

func (*FakeSubCollectorCPU) Run

func (s *FakeSubCollectorCPU) Run()

type FakeSubCollectorMemory

type FakeSubCollectorMemory struct {
}

func (*FakeSubCollectorMemory) CollectLocalMetrics

func (s *FakeSubCollectorMemory) CollectLocalMetrics(metricInfo *local.LocalMetricInfo, start time.Time, window metav1.Duration) ([]*prompb.TimeSeries, error)

func (*FakeSubCollectorMemory) Run

func (s *FakeSubCollectorMemory) Run()

Jump to

Keyboard shortcuts

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