apiserver

package
v0.0.0-...-96328d6 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 6 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrNotCompiled is returned if kubernetes apiserver support is not compiled in.
	// User classes should handle that case as gracefully as possible.
	ErrNotCompiled = errors.New("kubernetes apiserver support not compiled in")
)

Functions

func GetKubeClient added in v0.9.0

func GetKubeClient(timeout time.Duration) (kubernetes.Interface, error)

GetKubeClient returns a Kubernetes client.

func GetMetadataMapBundleOnAllNodes

func GetMetadataMapBundleOnAllNodes(_ *APIClient) (*apiv1.MetadataResponse, error)

GetMetadataMapBundleOnAllNodes is used for the CLI svcmap command to run fetch the service map of all nodes.

func GetMetadataMapBundleOnNode

func GetMetadataMapBundleOnNode(nodeName string) (*apiv1.MetadataResponse, error)

GetMetadataMapBundleOnNode is used for the CLI svcmap command to output given a nodeName

func GetNodeLabels

func GetNodeLabels(_ *APIClient, nodeName string) (map[string]string, error)

GetNodeLabels retrieves the labels of the queried node from the cache of the shared informer.

func GetPodMetadataNames

func GetPodMetadataNames(nodeName, ns, podName string) ([]string, error)

GetPodMetadataNames is used when the API endpoint of the DCA to get the services of a pod is hit.

func GetStatus

func GetStatus() map[string]interface{}

GetStatus returns various information about the datadog client(s)

Types

type APIClient

type APIClient struct {
	Cl interface{}
}

APIClient provides authenticated access to the

func GetAPIClient

func GetAPIClient() (*APIClient, error)

GetAPIClient returns the shared ApiClient instance.

func WaitForAPIClient added in v0.9.0

func WaitForAPIClient(ctx context.Context) (*APIClient, error)

WaitForAPIClient returns the shared ApiClient instance.

Directories

Path Synopsis
Package leaderelection provides functions related with the leader election mechanism offered in Kubernetes.
Package leaderelection provides functions related with the leader election mechanism offered in Kubernetes.
metrics
Package metrics provides telemetry to know who's the leader in Kubernetes objects that implement the leader/follower pattern.
Package metrics provides telemetry to know who's the leader in Kubernetes objects that implement the leader/follower pattern.

Jump to

Keyboard shortcuts

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