Documentation ¶
Index ¶
- Constants
- func GenerateMockPods(namespaceNum, workloadNum, podNumPerWorkload int) []*v1.Pod
- func NewMockCollector(ctx context.Context, baseCtx *katalystbase.GenericContext, ...) (collector.MetricCollector, error)
- func ReplaceMetaInformerWithMockData(baseCtx *katalystbase.GenericContext, conf *config.Configuration)
- type MockCollector
Constants ¶
View Source
const MetricCollectorNameMock = "mock-collector"
View Source
const MetricStoreNameMockLocalMemory = "mock-local-memory-store"
Variables ¶
This section is empty.
Functions ¶
func GenerateMockPods ¶
func NewMockCollector ¶
func NewMockCollector(ctx context.Context, baseCtx *katalystbase.GenericContext, genericConf *metric.GenericMetricConfiguration, collectConf *metric.CollectorConfiguration, mockConf *metric.MockConfiguration, metricStore store.MetricStore, ) (collector.MetricCollector, error)
func ReplaceMetaInformerWithMockData ¶
func ReplaceMetaInformerWithMockData(baseCtx *katalystbase.GenericContext, conf *config.Configuration)
Types ¶
type MockCollector ¶
type MockCollector struct {
// contains filtered or unexported fields
}
MockCollector produces mock data for test.
func (*MockCollector) Name ¶
func (m *MockCollector) Name() string
func (*MockCollector) Start ¶
func (m *MockCollector) Start() error
func (*MockCollector) Stop ¶
func (m *MockCollector) Stop() error
Click to show internal directories.
Click to hide internal directories.