metricwebhook

package
v0.0.0-...-c0d2ad2 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2020 License: Apache-2.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

View Source
const ControllerName = "metricwebhook-controller"
View Source
const ReconcilerName = "metricwebhook-reconciler"

Variables

This section is empty.

Functions

func Add

func Add(mgr manager.Manager) error

Add creates a new MetricWebhook Controller and adds it to the Manager. It will start it when the Manager is started.

func NewReconcileMetricWebhook

func NewReconcileMetricWebhook(mgr manager.Manager) (reconcile.Reconciler, error)

Types

type MetricMeasurementClient

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

func NewMetricValuesClient

func NewMetricValuesClient(metricsClient metricsclient.MetricsClient, k8sClient *k8s.Clientset) *MetricMeasurementClient

func (*MetricMeasurementClient) GetCurrentPodAverageValue

func (f *MetricMeasurementClient) GetCurrentPodAverageValue(name string, namespace string, labelSelector metav1.LabelSelector, targetAverageValue resource.Quantity) (averageValue resource.Quantity, time time.Time, err error)

func (*MetricMeasurementClient) GetCurrentResourceAverageUtilization

func (f *MetricMeasurementClient) GetCurrentResourceAverageUtilization(name v1.ResourceName, namespace string, labelSelector metav1.LabelSelector, targetAverageUtilization int32) (averageUtilization int32, averageValue resource.Quantity, time time.Time, err error)

func (*MetricMeasurementClient) GetCurrentResourceAverageValue

func (f *MetricMeasurementClient) GetCurrentResourceAverageValue(name v1.ResourceName, namespace string, labelSelector metav1.LabelSelector, targetAverageValue resource.Quantity) (averageValue resource.Quantity, time time.Time, err error)

type MetricNotificationClient

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

func NewDefaultMetricAlertClient

func NewDefaultMetricAlertClient() *MetricNotificationClient

func NewMetricAlertClient

func NewMetricAlertClient(httpClient *http.Client) *MetricNotificationClient

type MetricWebhookReconciler

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

func (*MetricWebhookReconciler) Reconcile

Reconcile reads that state of the cluster for a MetricWebhook object and sends out metric notification based on the config defined in MetricWebhook.Spec and current metric measurements

Jump to

Keyboard shortcuts

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