bbc

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: 42 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PodAnnotationSpecificSubnets = "cce.io/subnets"
)

Variables

This section is empty.

Functions

func GetPodSpecificSubnetsFromAnnotation

func GetPodSpecificSubnetsFromAnnotation(pod *v1.Pod) []string

func NewIPAM

func NewIPAM(
	kubeClient kubernetes.Interface,
	crdClient versioned.Interface,
	kubeInformer informers.SharedInformerFactory,
	crdInformer crdinformers.SharedInformerFactory,
	bceClient cloud.Interface,
	cniMode types.ContainerNetworkMode,
	vpcID string,
	clusterID string,
	gcPeriod time.Duration,
	batchAddIPNum int,
	ipMutatingRate float64,
	ipMutatingBurst int64,
	idleIPPoolMinSize int,
	idleIPPoolMaxSize int,
	debug bool,
) (ipam.Interface, error)

func PodNeedsSpecificSubnets

func PodNeedsSpecificSubnets(pod *v1.Pod) bool

Types

type IPAM

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

func (*IPAM) Allocate

func (ipam *IPAM) Allocate(ctx context.Context, name, namespace, containerID string) (*v1alpha1.WorkloadEndpoint, error)

func (*IPAM) Ready

func (ipam *IPAM) Ready(ctx context.Context) bool

func (*IPAM) Release

func (ipam *IPAM) Release(ctx context.Context, name, namespace, containerID string) (*v1alpha1.WorkloadEndpoint, error)

func (*IPAM) Run

func (ipam *IPAM) Run(ctx context.Context, stopCh <-chan struct{}) error

Jump to

Keyboard shortcuts

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