common

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Overview

Package common contains variables that are used in controller code and in other places too the reason of that package is to avoid conflict during initialization k8s client for e2e test

Index

Constants

View Source
const (

	// DeafultNodeIDAnnotationKey hold special ID for node object if external annotaion is not used
	DeafultNodeIDAnnotationKey = nodeKey + "/uuid"
	// NodeIDTopologyLabelKey used as a label key in external component csi-provisioner
	NodeIDTopologyLabelKey = DeafultNodeIDAnnotationKey
)

Variables

This section is empty.

Functions

func WithFeatureConfig added in v1.3.0

func WithFeatureConfig(featureConf featureconfig.FeatureChecker) func(*service)

WithFeatureConfig set feature config for service

func WithRetryDelay added in v1.3.0

func WithRetryDelay(delay time.Duration) func(*service)

WithRetryDelay declare delay between retries for ObtainNodeID

func WithRetryNumber added in v1.3.0

func WithRetryNumber(count int) func(*service)

WithRetryNumber declare number of retries for ObtainNodeID

Types

type NodeAnnotation added in v1.3.0

type NodeAnnotation interface {
	ObtainNodeID(nodeName string) (nodeID string, err error)
	GetNodeID(node *corev1.Node, annotationKey, nodeSelector string) (string, error)
	SetFeatureConfig(featureConf featureconfig.FeatureChecker)
}

NodeAnnotation represent annotation service

func New added in v1.3.0

func New(client k8sClient.Client, log *logrus.Logger, options ...func(*service)) NodeAnnotation

New return NodeAnnotation service

Jump to

Keyboard shortcuts

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