custommetrics

package
v0.0.0-...-0737ae5 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2020 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (

	//MetricSuffix the suffix of lag metric
	MetricSuffix = "-lag"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type KafkaMetricsClient

type KafkaMetricsClient interface {
	GetCustomMetric(request MetricRequest, metricSelector labels.Selector) (float64, error)
}

KafkaMetricsClient provides methods for accessing Kafka clusters APIs

func NewClient

func NewClient(client client.Client) KafkaMetricsClient

NewClient creates a client for calling Application

type KafkaTopicMetricsClient

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

KafkaTopicMetricsClient is used to call kafka to get metrics per client

func (KafkaTopicMetricsClient) GetCustomMetric

func (c KafkaTopicMetricsClient) GetCustomMetric(request MetricRequest, metricSelector labels.Selector) (float64, error)

GetCustomMetric calls kafka to retrieve the value of the metric requested

type MetricRequest

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

MetricRequest represents options

func NewMetricRequest

func NewMetricRequest(info provider.CustomMetricInfo, namespacedname types.NamespacedName) MetricRequest

NewMetricRequest creates a new metric request with defaults for optional parameters

Jump to

Keyboard shortcuts

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