instanceidhandler

package
v0.0.116 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2023 License: Apache-2.0 Imports: 9 Imported by: 10

Documentation

Index

Constants

View Source
const (
	ImageTagAnnotationKey   = annotationPrefix + "/image-tag"
	InstanceIDAnnotationKey = annotationPrefix + "/instance-id"
	StatusAnnotationKey     = annotationPrefix + "/status"
	WlidAnnotationKey       = annotationPrefix + "/wlid"
)

annotations

Variables

This section is empty.

Functions

func GenerateInstanceID

GenerateInstanceID generates instance ID from workload

func GenerateInstanceIDFromPod added in v0.0.114

func GenerateInstanceIDFromPod(pod *core1.Pod) ([]instanceidhandler.IInstanceID, error)

GenerateInstanceIDFromPod generates instance ID from pod

func GenerateInstanceIDFromString added in v0.0.114

func GenerateInstanceIDFromString(input string) (instanceidhandler.IInstanceID, error)

GenerateInstanceIDFromString generates instance ID from string The string format is: apiVersion-<apiVersion>/namespace-<namespace>/kind-<kind>/name-<name>/containerName-<containerName>

Types

type InstanceID

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

func (*InstanceID) GetAPIVersion

func (id *InstanceID) GetAPIVersion() string

func (*InstanceID) GetContainerName

func (id *InstanceID) GetContainerName() string

func (*InstanceID) GetHashed added in v0.0.114

func (id *InstanceID) GetHashed() string

func (*InstanceID) GetKind

func (id *InstanceID) GetKind() string

func (*InstanceID) GetLabels

func (id *InstanceID) GetLabels() map[string]string

func (*InstanceID) GetName

func (id *InstanceID) GetName() string

func (*InstanceID) GetNamespace

func (id *InstanceID) GetNamespace() string

func (*InstanceID) GetStringFormatted

func (id *InstanceID) GetStringFormatted() string

func (*InstanceID) SetAPIVersion

func (id *InstanceID) SetAPIVersion(apiVersion string)

func (*InstanceID) SetContainerName

func (id *InstanceID) SetContainerName(containerName string)

func (*InstanceID) SetKind

func (id *InstanceID) SetKind(kind string)

func (*InstanceID) SetName

func (id *InstanceID) SetName(name string)

func (*InstanceID) SetNamespace

func (id *InstanceID) SetNamespace(namespace string)

Jump to

Keyboard shortcuts

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