utils

package
v0.61.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindOwnerWithKind

func FindOwnerWithKind(ors []metav1.OwnerReference, kind string) *metav1.OwnerReference

FindOwnerWithKind returns the OwnerReference of the matching kind from the provided list of owner references.

func GetDoubleTimeSeries added in v0.47.0

func GetDoubleTimeSeries(val float64) *v1.TimeSeries

func GetDoubleTimeSeriesWithLabels added in v0.47.0

func GetDoubleTimeSeriesWithLabels(val float64, labelVals []*v1.LabelValue) *v1.TimeSeries

func GetIDForCache

func GetIDForCache(namespace string, resourceName string) string

GetIDForCache returns keys to lookup resources from the cache exposed by shared informers.

func GetInt64TimeSeries

func GetInt64TimeSeries(val int64) *v1.TimeSeries

func GetInt64TimeSeriesWithLabels

func GetInt64TimeSeriesWithLabels(val int64, labelVals []*v1.LabelValue) *v1.TimeSeries

func GetUIDForObject

func GetUIDForObject(obj runtime.Object) (types.UID, error)

GetUIDForObject returns the UID for a Kubernetes object.

func StringSliceToMap

func StringSliceToMap(strings []string) map[string]bool

StringSliceToMap converts a slice of strings into a map with keys from the slice

func StripContainerID

func StripContainerID(id string) string

StripContainerID returns a pure container id without the runtime scheme://.

Types

This section is empty.

Jump to

Keyboard shortcuts

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