worker

package
v0.0.0-...-432d548 Latest Latest
Warning

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

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

Documentation

Overview

Package worker is a generated GoMock package.

Package worker is a generated GoMock package.

Package mock_worker is a generated GoMock package.

Package mock_worker is a generated GoMock package.

Package worker is a generated GoMock package.

Index

Constants

View Source
const (
	SchedulerNameMock           = "mock"
	HippoPriorityClassPrefix    = "hippo-priority"
	C2DeleteProtectionFinalizer = "protection-delete.pod.c2/service"
)

LabelKeys

View Source
const (
	// AliyunEni Elastic Network Interface https://www.alibabacloud.com/help/zh/doc-detail/58496.htm
	AliyunEni = "aliyun/eni"
	// K8SStdResourceKeyDISK k8s standard disk resource key
	K8SStdResourceKeyDISK = "ephemeral-storage"
)
View Source
const (
	HealthStatusOffline  = -1
	HealthStatusPsFailed = 1
)

pod healthscore

View Source
const (
	// SuccessSynced is used as part of the Event 'reason' when a WorkerNode is synced
	SuccessSynced = "Synced"
)

Variables

This section is empty.

Functions

func EscapeGroupID

func EscapeGroupID(groupID string) string

EscapeGroupID escape groupID

Types

type Controller

type Controller struct {
	schema.GroupVersionKind
	controller.DefaultController
	// contains filtered or unexported fields
}

Controller is the controller implementation for workernode resources

func NewController

func NewController(
	carbonclientset clientset.Interface,
	kubeclientset kubernetes.Interface,
	workerInformer informers.WorkerNodeInformer,
	serviceInformer informers.ServicePublisherInformer,
	rollingSetInformer informers.RollingSetInformer,
	podInformer coreinformers.PodInformer,
	configMapInformer coreinformers.ConfigMapInformer,
	writeLabels map[string]string) *Controller

NewController returns a new workerallocator controller

func (*Controller) DeleteSubObj

func (c *Controller) DeleteSubObj(namespace, key string) error

DeleteSubObj do garbage collect

func (*Controller) GetObj

func (c *Controller) GetObj(namespace, key string) (interface{}, error)

GetObj grep worker

func (*Controller) Sync

func (c *Controller) Sync(key string) error

Sync compares the actual state with the desired, and attempts to converge the two.

func (*Controller) WaitForCacheSync

func (c *Controller) WaitForCacheSync(stopCh <-chan struct{}) bool

WaitForCacheSync wait informers synced

type Mockexecutor

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

Mockexecutor is a mock of executor interface.

func NewMockexecutor

func NewMockexecutor(ctrl *gomock.Controller) *Mockexecutor

NewMockexecutor creates a new mock instance.

func (*Mockexecutor) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockexecutorMockRecorder

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

MockexecutorMockRecorder is the mock recorder for Mockexecutor.

type MockpodSpecSyncer

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

MockpodSpecSyncer is a mock of podSpecSyncer interface.

func NewMockpodSpecSyncer

func NewMockpodSpecSyncer(ctrl *gomock.Controller) *MockpodSpecSyncer

NewMockpodSpecSyncer creates a new mock instance.

func (*MockpodSpecSyncer) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockpodSpecSyncer) MergeWebHooks

func (m *MockpodSpecSyncer) MergeWebHooks(targetPod *v10.Pod, podSpec *v10.PodSpec, currentPod *v10.Pod) error

MergeWebHooks mocks base method.

type MockpodSpecSyncerMockRecorder

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

MockpodSpecSyncerMockRecorder is the mock recorder for MockpodSpecSyncer.

func (*MockpodSpecSyncerMockRecorder) MergeWebHooks

func (mr *MockpodSpecSyncerMockRecorder) MergeWebHooks(targetPod, podSpec, currentPod interface{}) *gomock.Call

MergeWebHooks indicates an expected call of MergeWebHooks.

type MockpodStatusParser

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

MockpodStatusParser is a mock of podStatusParser interface.

func NewMockpodStatusParser

func NewMockpodStatusParser(ctrl *gomock.Controller) *MockpodStatusParser

NewMockpodStatusParser creates a new mock instance.

func (*MockpodStatusParser) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockpodStatusParserMockRecorder

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

MockpodStatusParserMockRecorder is the mock recorder for MockpodStatusParser.

type Mockprocessor

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

Mockprocessor is a mock of processor interface.

func NewMockprocessor

func NewMockprocessor(ctrl *gomock.Controller) *Mockprocessor

NewMockprocessor creates a new mock instance.

func (*Mockprocessor) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockprocessorMockRecorder

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

MockprocessorMockRecorder is the mock recorder for Mockprocessor.

type Mockscheduler

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

Mockscheduler is a mock of scheduler interface

func NewMockscheduler

func NewMockscheduler(ctrl *gomock.Controller) *Mockscheduler

NewMockscheduler creates a new mock instance

func (*Mockscheduler) EXPECT

EXPECT returns an object that allows the caller to indicate expected use

type MockschedulerMockRecorder

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

MockschedulerMockRecorder is the mock recorder for Mockscheduler

type MockworkerAdjuster

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

MockworkerAdjuster is a mock of workerAdjuster interface

func NewMockworkerAdjuster

func NewMockworkerAdjuster(ctrl *gomock.Controller) *MockworkerAdjuster

NewMockworkerAdjuster creates a new mock instance

func (*MockworkerAdjuster) EXPECT

EXPECT returns an object that allows the caller to indicate expected use

type MockworkerAdjusterMockRecorder

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

MockworkerAdjusterMockRecorder is the mock recorder for MockworkerAdjuster

type MockworkerAllocator

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

MockworkerAllocator is a mock of workerAllocator interface.

func NewMockworkerAllocator

func NewMockworkerAllocator(ctrl *gomock.Controller) *MockworkerAllocator

NewMockworkerAllocator creates a new mock instance.

func (*MockworkerAllocator) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockworkerAllocatorMockRecorder

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

MockworkerAllocatorMockRecorder is the mock recorder for MockworkerAllocator.

type MockworkerStateMachine

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

MockworkerStateMachine is a mock of workerStateMachine interface.

func NewMockworkerStateMachine

func NewMockworkerStateMachine(ctrl *gomock.Controller) *MockworkerStateMachine

NewMockworkerStateMachine creates a new mock instance.

func (*MockworkerStateMachine) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockworkerStateMachineMockRecorder

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

MockworkerStateMachineMockRecorder is the mock recorder for MockworkerStateMachine.

type MockworkerUpdater

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

MockworkerUpdater is a mock of workerUpdater interface.

func NewMockworkerUpdater

func NewMockworkerUpdater(ctrl *gomock.Controller) *MockworkerUpdater

NewMockworkerUpdater creates a new mock instance.

func (*MockworkerUpdater) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockworkerUpdaterMockRecorder

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

MockworkerUpdaterMockRecorder is the mock recorder for MockworkerUpdater.

Jump to

Keyboard shortcuts

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