networking

package
v1.9.6 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	AnnotationCCEPrefix = "cce.baidubce.com/"
	// annotation for PodSubnetTopologySpread
	AnnotationPodSubnetTopologySpread = AnnotationCCEPrefix + "PodSubnetTopologySpread"

	// cce defined k8s resource name
	ResourceIPForNode  = corev1.ResourceName(AnnotationCCEPrefix + "ip")
	ResourceENIForNode = corev1.ResourceName(AnnotationCCEPrefix + "eni")

	// CrossVPCEni resource name
	ResourceCrossVPCEni = corev1.ResourceName("cross-vpc-eni.cce.io/eni")

	// topodlogy key for psts
	TopologyKeyOfPod = "topology.kubernetes.io/zone"
	// AnnotationDisablePSTSPodAffinity This annotation is included on the pod, which means that the pod does not expect to use the scheduling function extended by pSTS
	AnnotationDisablePSTSPodAffinity = AnnotationCCEPrefix + "DisablePodSubnetTopologySpreadScheduler"
)

Functions

func GetPSTSStrategy added in v1.6.12

GetPSTSStrategy Recursively obtain the IP application policy

func GetPodSubnetTopologySpreadName

func GetPodSubnetTopologySpreadName(pod *corev1.Pod) string

func GetReleaseStrategy

GetReleaseStrategy defaults to release strategy is TTL

func ISCustomReuseModeWEP added in v1.6.12

func ISCustomReuseModeWEP(wep *networkingv1alpha1.WorkloadEndpoint) bool

IsCustomReuseModeWEP WorkloadEndpoint type is custom

func IsCustomMode added in v1.6.12

IsCustomMode psts type is custom

func IsEndWithNum

func IsEndWithNum(name string) bool

func IsFixIPStatefulSetPodWep added in v1.6.12

func IsFixIPStatefulSetPodWep(wep *networkingv1alpha1.WorkloadEndpoint) bool

func IsReuseIPCustomPSTS added in v1.6.12

func IsReuseIPCustomPSTS(psts *networkingv1alpha1.PodSubnetTopologySpread) bool

IsReuseIPCustomPSTS whether to enable the reuse IP mode

func IsSubnetTopologySpreadPod

func IsSubnetTopologySpreadPod(pod *corev1.Pod) bool

Whether pod complies with the topology distribution of pod subnet

func NeedReleaseReuseModeWEP added in v1.6.12

func NeedReleaseReuseModeWEP(wep *networkingv1alpha1.WorkloadEndpoint) bool

func PSTSContainsAvailableSubnet

func PSTSContainsAvailableSubnet(psts *networkingv1alpha1.PodSubnetTopologySpread) bool

PSTSContainsAvailableSubnet whatever length of the available subnet of psts greater than 0

func PSTSMode added in v1.6.12

PSTSMode slecte mod of psts and return true if a available subnet in psts

Types

This section is empty.

Jump to

Keyboard shortcuts

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