v1

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

Documentation

Overview

Package v1 is the v1 version of the API.

Index

Constants

View Source
const (
	ReasonNotExist          = "Service Not Exist Node"
	ReasonServiceCheckFalse = "Service Check False"
	ReasonQueryError        = "Query NameService With Error"
	ReasonWarmUP            = "Node In Warmup"

	NodeHasPublished = "Node Published"
)
View Source
const (
	// SchedulerName
	SchedulerNameHippo   = "hippo"
	SchedulerNameAsi     = "default-scheduler"
	SchedulerNameDefault = "default-scheduler"
	SchedulerNameAck     = "ack"
	SchedulerNameC2      = "c2-allocator"

	// subrs
	LabelKeySchedulerName     = "app.c2.io/scheduler-name"
	LabelKeyMigratedFromSubrs = "app.c2.io/migrated-from-subrs"
	DefaultShortSubRSLabelKey = "app.c2.io/short-subrs-name"
	DefaultSubRSLabelKey      = "app.c2.io/subrs-name"
	SubrsTextPrefix           = "subrs.c2.io/"

	// quickonline
	LabelKeyPreInactive      = "app.c2.io/pre-inactive"
	LabelKeyInactive         = "app.c2.io/inactive"
	LabelKeyOnlined          = "app.c2.io/onlined"
	LabelAllContainersStatus = "alibabacloud.com/all-containers-status"

	LabelBizPodFlag = "alibabacloud.com/biz-pod"

	// unassigned info
	LabelKeyUnassignedReason = "app.c2.io/unassigned-reason"
	LabelKeyUnassignedMsg    = "app.c2.io/unassigned-msg"
	// DefaultRollingsetUniqueLabelKey is the default key of the selector that is added
	// to existing RCs (and label key that is added to its pods) to prevent the existing RCs
	// to select new pods (and old pods being select by new RC).
	DefaultRollingsetUniqueLabelKey string = "rs-version-hash"
	DefaultReplicaUniqueLabelKey    string = "replica-version-hash"
	DefaultGangUniqueLabelKey       string = "gang-version-hash"
	DefaultWorkernodeUniqueLabelKey string = "worker-version-hash"
	DefaultShardGroupUniqueLabelKey string = "shardgroup" // memkube default batchkey
	DefaultSlotsetUniqueLabelKey    string = "ss-version-hash"

	// hippo label keys
	LabelAsiOwner         = "alibabacloud.com/owner"
	LabelKeyAppName       = "app.hippo.io/app-name"
	LabelKeyZoneName      = "app.hippo.io/zone-name"
	LabelKeyAppChecksum   = "app.hippo.io/app-checksum" // for admin-manager
	LabelKeyClusterName   = "app.hippo.io/cluster-name"
	LabelKeyRoleName      = "app.hippo.io/role-name"
	LabelKeySubrsName     = "app.c2.io/subrs-short-name"
	LabelGangPartName     = "app.c2.io/gang-part-name"
	LabelGangMainPart     = "app.c2.io/main-part"
	AnnoGangPlan          = "app.c2.io/gang-plan"
	AnnoBecomeCurrentTime = "app.hippo.io/become-current-time"
	// NOTE: this key is only used in c2, bad key name
	LabelKeyGroupName          = "app.hippo.io/group-name"
	LabelKeyRequirementID      = "app.hippo.io/requirementId"
	LabelKeyExlusive           = "app.hippo.io/exclusive-labels"
	LabelKeyDeclare            = "app.hippo.io/declare-label"
	LabelKeyQuotaGroupID       = "app.hippo.io/quotaGroupId"
	LabelKeyMaxInstancePerNode = "app.hippo.io/maxInstancePerNode"
	LabelKeyExclusiveMode      = "app.hippo.io/exclusiveMode"
	LabelKeyHippoPreference    = "app.hippo.io/preference"
	LabelKeyCarbonJobName      = "app.hippo.io/carbonjob-name" // NOTE: the value maybe a hash by LabelHashValue
	LabelKeyRoleShortName      = "app.hippo.io/roleShortName"
	LabelKeyAppShortName       = "app.hippo.io/appShortName"
	LabelKeyAutoUpdate         = "app.hippo.io/autoUpdate"
	LabelKeyBackupPod          = "app.hippo.io/backupPod"
	LabelKeyPodVersion         = "app.hippo.io/pod-version"
	LabelKeyPreemptable        = "app.hippo.io/preemptable"
	LabelKeyLaunchSignature    = "app.hippo.io/launch-signature"
	LabelKeyPackageChecksum    = "app.hippo.io/package-checksum"
	LabelKeyServiceVersion     = "app.c2.io/service-version"

	LabelKeyInstanceGroup        = "sigma.ali/instance-group"
	LabelKeyAppStage             = "sigma.alibaba-inc.com/app-stage"
	LabelKeyAppUnit              = "sigma.alibaba-inc.com/app-unit"
	LabelKeySkylineInitContainer = "app.c2.io/skyline-init-container"
	LabelKeyDependentSkyline     = "app.c2.io/dependent-skyline"
	LabelKeySigmaAppName         = "sigma.ali/app-name"    // compatible to old sigma protocol
	LabelKeySigmaDeplyUnit       = "sigma.ali/deploy-unit" // compatible
	LabelInjectSidecar           = "alibabacloud.com/inject-staragent-sidecar"
	LabelSigmaInjectSidecar      = "sigma.ali/inject-staragent-sidecar"
	LabelKeyReplaceNodeVersion   = "app.c2.io/replace-node-version"

	LabelKeyFedInstanceGroup = "sigma.ali/fed-instance-group"
	LabelKeyFedAppStage      = "sigma.alibaba-inc.com/fed-app-stage"
	LabelKeyFedAppUnit       = "sigma.alibaba-inc.com/fed-app-unit"

	// asi
	LabelAsiAppName             = "app.kubernetes.io/name"
	LabelDeployUnit             = "app.alibabacloud.com/deploy-unit"
	LabelObjSource              = "app.hippo.com/object-source"
	LabelConstraint             = "alibabacloud.com/pod-constraint-name"
	LabelHippoPodVersion        = "app.hippo.io/pod-version"
	LabelDisableAdmission       = "alibabacloud.com/disable-admission"
	LabelAntBizGroup            = "meta.k8s.alipay.com/biz-group-id"
	LabelAntBizName             = "meta.k8s.alipay.com/biz-name"
	LabelCPUBindStrategy        = "alibabacloud.com/cpuBindStrategy"
	LabelAsiMountGPU            = "alibabacloud.com/mount-nvidia-driver-compatible"
	LabelInplaceUpdateForbidden = "alibabacloud.com/inplace-update-forbidden"
	LabelKeyNoMountCgroup       = "alibabacloud.com/no-mount-cgroup"

	AnnotationCPUQuota = "pod.beta1.alibabacloud.com/container-cpu-quota-unlimit"
	AnnotationSSH      = "pod.beta1.alibabacloud.com/sshd-in-staragent"
	AnnotationSN       = "pods.sigma.alibaba-inc.com/inject-pod-sn"

	// c2 skyline register
	AnnotationKeyC2HostnameTemplate = "app.c2.io/hostname-template"
	LabelKeyC2InstanceGroup         = "app.c2.io/instance-group"
	LabelKeyC2AppStage              = "app.c2.io/app-stage"
	LabelKeyC2AppUnit               = "app.c2.io/app-unit"

	FinaliezrKeyC2SkylineRegister      = "app.c2.io/skyline-register"
	FinaliezrKeyC2SkylinePreProtection = "protection-delete.pod.c2/naming-pre-register"
	FinaliezrKeyC2SkylineProtection    = "protection-delete.pod.c2/naming"
	ConditionKeyC2Initialize           = "app.c2.io/initialize"

	// serverless
	LabelPoolStatus              = "serverless.io/pool-status"
	LabelRuntimeAppName          = "serverless.io/runtime-app-name"
	AnnotationSubrsMetas         = "serverless.io/subrs-metas"
	LabelSubrsEnable             = "serverless.io/subrs-enable"
	LabelServerlessAppName       = "serverless.io/app-name"
	LabelServerlessInstanceGroup = "serverless.io/instance-group"
	LabelServerlessAppId         = "serverless.io/app-id"
	LabelServerlessRecycleModel  = "serverless.io/recycle-mode"
	AnnotationPoolSpec           = "serverless.io/pool-spec"

	AnnoServerlessAppPlanStatus = "serverless.io/app-plan-status"
	AnnoServerlessAppStatus     = "serverless.io/app-status"

	ServerlessPlatform = "serverless"

	// Pool Status
	PoolStatusWaiting = "waiting"
	PoolStatusCreated = "created"
	PoolStatusDeleted = "deleted"

	// asi label keys
	LabelKeyPlatform            = "alibabacloud.com/platform"
	LabelKeyBU                  = "alibabacloud.com/bu"
	LabelPodEvictionProcessor   = "pod.sigma.ali/eviction-processor"
	LabelPodEvictionLegacySigma = "pod.sigma.ali/eviction" // legacy sigma eviction protocol
	LabelKeyPodSN               = "sigma.ali/sn"
	LabelGpuCardModel           = "alibabacloud.com/gpu-card-model"
	LabelFinalStateUpgrading    = "inplaceset.beta1.sigma.ali/final-state-upgrading"

	// These *Hash below are used to select in proxy
	LabelKeyC2GroupName   = "app.c2.io/group-name"
	LabelKeyRoleNameHash  = "app.c2.io/role-name-hash"
	LabelKeyGroupNameHash = "app.c2.io/group-name-hash"
	LabelKeyZoneNameHash  = "app.c2.io/zone-name-hash"
	LabelKeyAppNameHash   = "app.c2.io/app-name-hash"

	LabelKeyBufferCapacityNameHash = "app.c2.io/buffer-capacity-name-hash"

	// hippo condition keys
	ConditionKeyScheduleStatusExtend = "app.hippo.io/ScheduleStatusExtend"
	ConditionKeyPodStatusExtend      = "app.hippo.io/PodStatusExtend"
	ConditionKeyPodPreference        = "app.hippo.io/PodPreference"
	ConditionKeyPodNetworkStatus     = "app.hippo.io/PodNetworkStatus"

	// ResourceIP means ip resource
	HippoResourcePrefix = "resource.hippo.io/"
	ResourceIP          = "resource.hippo.io/ip"
	ResourceCPU         = "cpu"
	ResourceMEM         = "memory"
	ResourceGPUMEM      = "gpu-memory"
	ResourceGPUCore     = "gpu-core"
	ResourceENI         = "eni"
	ResourceDISKPrefix  = "resource.hippo.io/disk_size_"
	ResourceDISK        = "resource.hippo.io/disk_size"
	ResourceGPU         = "nvidia.com/gpu"
	ResourceFPGA        = "xilinx.com/fpga"
	ResourceNPU         = "alibaba.com/npu"
	ResourcePOV         = "alibaba.com/pov"
	ResourceDiskRatio   = "alibabacloud.com/disk_ratio"
	ResourceRequestCpu  = "requests.cpu"

	ASIResourceKeyIP       corev1.ResourceName = "alibabacloud.com/ip"
	ASIResourceKeyGPU      corev1.ResourceName = "alibabacloud.com/gpu"
	ASIResourceKeyGPUMEM   corev1.ResourceName = "alibabacloud.com/gpu-mem"
	ASIResourceKeyGPUCore  corev1.ResourceName = "alibabacloud.com/gpu-core"
	ASIResourceKeyFPGA     corev1.ResourceName = "alibabacloud.com/fpga"
	ASIResourceKeyNPU      corev1.ResourceName = "alibabacloud.com/npu"
	ASIResourceKeyPOV      corev1.ResourceName = "alibabacloud.com/pov"
	ASIResourceKeyDISK     corev1.ResourceName = "ephemeral-storage"
	ASIResourceKeyUnderlay corev1.ResourceName = "alibabacloud.com/underlay"

	// c2 extend labels keys
	ControllersShardKey   string = "app.c2.io/controllers-shard"
	WorkerRoleKey         string = "app.c2.io/worker-role"
	GroupTypeKey          string = "app.c2.io/group-type"
	WorkerReferReplicaKey string = "app.c2.io/worker-refer"
	BizKeyPrefix          string = "app.c2.io/biz-"
	AnnoKeyRoleRequest    string = "app.c2.io/role-request"
	// 次前缀开头的annotation不参与rolling计算
	BizDetailKeyPrefix         string = "app.c2.io/biz-detail"
	BizDetailKeyPartitionCount string = "app.c2.io/biz-detail-partition-count"
	BizDetailKeyReady          string = "app.c2.io/biz-detail-ready"
	// cm2 metas
	BizCm2MetasKeyPrefix string = "app.c2.io/biz-cm2-metas-"

	AnnoKeyEvictFailedMsg string = "alibabacloud.com/evict-failed-msg"

	BizDetailKeyGangInfo string = "app.c2.io/biz-detail-ganginfo"
	// BizMeatsKeys
	BizMeatsKeyHIPPOCluster     = "HIPPO_CLUSTER"
	BizMeatsKeyHIPPOAPP         = "HIPPO_APP"
	BizMeatsKeyHIPPORole        = "HIPPO_ROLE"
	BizMeatsKeyC2Group          = "C2_GROUP"
	BizMeatsKeyC2Role           = "C2_ROLE"
	CM2MetaWeightKey            = "target_weight"
	CM2MetaTopoInfo             = "topo_info"
	CM2MetaWeightWarmupValue    = "-100"
	CM2MetaWeightWarmupValueInt = -100

	// c2 envs
	C2EnvsRestart            = "C2_ENVS_RESTART__"
	C2EnvContainerWorkingDir = "WORKING_DIR"

	ContainerConfigEnvPrefix = "containerConfig_"

	// c2 extend labels values
	CurrentWorkerKey        string = "current"
	BackupWorkerKey         string = "backup"
	GroupTypeShardGroup     string = "group"
	GroupTypeRollingset     string = "role"
	GroupTypeGangRollingset string = "gang-role"
	GroupTypeReplica        string = "replica"

	// FinalizerSmoothDeletion Finalizer字段
	FinalizerSmoothDeletion string = "smoothDeletion"

	// FinalizerPoolDeletion 删除Pool
	FinalizerPoolDeletion string = "serverless.io.pool"

	// To store the original hippo application description
	AnnotationKeyApplicationDescription = "app.c2.io/application-description"
	// To store the user keys
	AnnotationC2DeclaredKeys    = "app.c2.io/c2-declared-keys"
	AnnotationC2DeclaredEnvKeys = "app.c2.io/c2-declared-env-keys"

	AnnotationKeySpecExtend     = "app.hippo.io/spec-extend"
	AnnotationKeySlotID         = "app.hippo.io/slotID"
	AnnotationKeyOldPriority    = "app.hippo.io/old-priority"
	AnnotationC2ResourceVersion = "app.c2.io/pod-resource-version"
	AnnotationC2PodVersion      = "app.c2.io/pod-version"
	AnnotationKeyPriorityV1     = "app.hippo.io/priority-v1.0"
	// For bizpod only right now
	AnnotationC2ContainerRuntime = "app.c2.io/container-runtime"
	AnnotationC2Spread           = "app.c2.io/spread"

	AnnotationOldPodLevelStorage = "sigma.ali/use-unified-pv"
	// 配置文档:https://yuque.antfin-inc.com/docs/share/cb242f8e-5a41-447d-8023-de1bbf029419?#
	AnnotationPodLevelStorageMode = "sigma.ali/app-storage-mode"

	// asi annotation key
	AnnotationStandbyStableStatus = "alibabacloud.com/standby-stable-status"

	AnnotationBufferCapacityResVersion   = "app.c2.io/buffer-capacity-res-version"
	AnnotationBufferCapacityMainRoleName = "app.c2.io/buffer-capacity-main-role-name"

	AnnotationInjectSystemd = "alibabacloud.com/need-inject-systemd-containers"

	AnnotationHostNameTemplate = "pod.beta1.sigma.ali/hostname-template"

	AnnotationScalerResourcePool = "alibabacloud.com/scaler-resource-pool"

	AnnotationPodDeletionCost   = "controller.kubernetes.io/pod-deletion-cost"
	AnnotationPodC2DeletionCost = "controller.kubernetes.io/original-pod-deletion-cost"

	// AnnotationCandidateClusters aligns with fed clusters filtering key.
	AnnotationCandidateClusters = "alibabacloud.com/cluster"
	// node-topology
	AnnotationNodeTopologyScope = "app.c2.io/node-topology-scope"

	//用户指定需要使用的云盘的策略,目前只有role-storage,即按照role级别分配一个,所有pod均使用该pvc
	AppStorageStrategyRole         = "role-storage"
	AnnotationAppStoragetStrategy  = "app.c2.io/app-storage-strategy"
	AnnotationAppStoragetMountPath = "app.c2.io/app-storage-mount-path"
	AnnotationAppStoragetSize      = "app.c2.io/app-storage-size"
	AnnotationRolePvcName          = "app.c2.io/app-role-pvc-name"
	StorageMountEnvKey             = "C2_NET_DISK_MOUNT_PATH"

	AnnotationWorkerUpdateStatus = "app.c2.io/update-status"
	AnnotationWorkerUpdatePhase  = "app.c2.io/update-phase-status"
	AnnotationBufferSwapRecord   = "app.c2.io/buffer-swap-record"
	// TopologyScop types
	TopologyScopGang = "gang"

	PodVersion2     = "v2.0"
	PodVersion25    = "v2.5"
	PodVersion3     = "v3.0"
	LazyPodVersion3 = "app.c2.io/lazy-v3.0"

	// inject identifier
	LabelKeyIdentifier = "app.c2.io/inject-identifier"
	IdentifierEnvKey   = "WORKER_IDENTIFIER_FOR_CARBON"

	C2AdminRoleTag    = "internal_appmaster_resource_tag"
	HippoAdminRoleTag = "__internal_appmaster_resource_tag__"

	WorkerNameSuffixA = "-a"
	WorkerNameSuffixB = "-b"

	UnifiedStorageInjectedVolumeName = "autogen"
	//
	GroupRollingSetBufferShortName = "grs-buffer"

	MainContainer = "main"

	AnnotationInitSpec         = "alibabacloud.com/init-spec"
	AnnotationInitResourceSpec = "alibabacloud.com/init-resource-spec"

	DefaultNamespace = "default"

	DirectLabelCopyMappingKey = "_direct"

	ExponentialBackoff = 10

	DefaultRestartCountLimit = 10

	// serverless & AIOS app meta info, see doc https://aliyuque.antfin.com/search-infra/pufssx/bux3yx7bw9626qsc for details
	LabelServerlessBizPlatform = "serverless.io/biz-platform"
	LabelServerlessAppStage    = "serverless.io/app-stage"
	AnnoServerlessAppDetail    = "serverless.io/app-detail-url" // only in annotation

	MaxFixedCost    int64 = 9999
	MinFixedCost    int64 = 5000
	MaxCyclicalCost int64 = 4999
	MinCyclicalCost int64 = 1

	AnnotationFiberScenes = "app.c2.io/fiber-scenes"
	LabelResourcePool     = "app.alibabacloud.com/pod-scale-kind"

	// spot-instance
	AnnotationC2SpotTarget = "app.c2.io/spot-target"
	LabelIsBackupPod       = "alibabacloud.com/is-backup"
	AnnotationBackupOf     = "alibabacloud.com/backup-of"
	// gang
	ScheduleGangRolling = "gang_rolling"

	LabelRuntimeID = "sigma.ali/runtime-id"

	C2PlatformKey = "app.c2.io/platform"

	ConditionServerlessAppReady = "ServerlessAppReady"
	ConditionWorkerNodeReady    = "WorkerNodeReady"

	ServerlessPlanSuccess    int32 = 1
	ServerlessPlanInProgress int32 = 2
	ServerlessPlanFailed     int32 = 3
	ServerlessServiceReady   int32 = 3

	FinalizerPodProtectionFmt = "protection.pod*"
)

Unique Label Keys used to select obj for

View Source
const (
	ExclusiveModeAPP  = "APP"
	ExclusiveModeTAG  = "TAG"
	ExclusiveModeNONE = "NONE"
)

ExclusviceMode

View Source
const (
	SilentNodeAnnoKey               = "app.c2.io/silentnode"
	SilentTimeAnnoKey               = "app.c2.io/silent-time"
	ColdResourceUpdateState         = "app.c2.io/cold-resource-update-state"
	ColdResourceUpdateTargetVersion = "app.c2.io/cold-resource-update-target-version"
	Standby2ActiveTimeAnnoKey       = "app.c2.io/standby-to-active-time"
)

Silent offline

View Source
const (
	//ColdUpdateStateColdToWarm change cold to warm
	ColdUpdateStateColdToWarm = "cold_to_warm"
	//ColdUpdateStateWaitingWarmAssgin warm resource update
	ColdUpdateStateWaitingWarmAssgin = "waiting_warm_assagin"
	//ColdUpdateStateWarmResourceReplace warm resource replace
	ColdUpdateStateWarmResourceReplace = "warm_resource_replace"
)
View Source
const (
	// DefaultRecoverStrategy 默认逻辑, 起新下老
	DefaultRecoverStrategy = ""

	// DirectReleasedRecoverStrategy 下老起新逻辑
	DirectReleasedRecoverStrategy = "directRelease"

	// NotRecoverStrategy 不recover
	NotRecoverStrategy = "notRecover"

	// RebuildDeadStrategy 容器dead时进行rebuild,下老起新
	RebuildDeadStrategy = "rebuildDead"
)
View Source
const (
	HostDead = 2
)

Hippo Health Scores

View Source
const (
	InitServiceFalseState = "init with false"
)

InitServiceFalseState

View Source
const LabelValueMaxLength int = 63

LabelValueMaxLength LabelValueMaxLength

View Source
const (
	MaxControllerShards = 16
)

MaxControllerShards descirbe max controllers in one namespace

Variables

View Source
var (
	// SchemeBuilder collects functions that add things to a scheme.
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	// AddToScheme applies all the stored functions to the scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var (
	// SystemNamespace is used for c2 system
	SystemNamespace = "kube-system"

	//DefaultAutoReserveMinutes is reserve time for delete pod
	DefaultAutoReserveMinutes = 3
	// DefaultMaxFailedCount is max recover failed count
	DefaultMaxFailedCount = 5
	// DefaultExclusiveMode  DefaultExclusiveMode
	DefaultExclusiveMode = ExclusiveModeTAG
	// DefaultMaxInstancePerNode DefaultMaxInstancePerNode
	DefaultMaxInstancePerNode = 1

	// MaxNameLength 最终生成的podname不能过长。不同版本长度限制不一样,目前按照1.14版本:253,留10个字节作为buffer, kubelet 创建目录 namespace + name + uid 不能超过 256 反推回来podname应在155以内
	MaxNameLength = 150
	// MaxNamespaceLength 最终生成的namespacee不能过长。不同版本长度限制不一样,目前按照1.14版本:253,留10个字节作为buffer
	MaxNamespaceLength = 63
	// MaxAppNameLength MaxAppNameLength
	MaxAppNameLength = 140
	// MaxRoleNameLength MaxRoleNameLength
	MaxRoleNameLength = 120

	// MaxGroupsPerApp is used to limit the maximum number of app
	MaxGroupsPerApp = 40000

	// HomeDiskPath HomeDiskPath
	HomeDiskPath = "/home,/home/admin,/home/admin/hippo"
	// NotScheduleTimeout for recover
	NotScheduleTimeout = 0

	CompresseShardThreshold = 256

	// RecordNotScheduleMetricThreshold for record metric
	RecordNotScheduleMetricThreshold = 300
)
View Source
var (
	ErrInvalidLengthGenerated        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenerated          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenerated = fmt.Errorf("proto: unexpected end of group")
)
View Source
var C2InternalMetaBlackList = []string{"serverless.io/rollout-id", "serverless.io/rollout-batch-id"}
View Source
var C2InternalMetaPrefix = []string{"serverless.io", "app.hippo.io", "app.c2.io"}

C2InternalMetaPrefix This is meant to be constant! Please don't mutate it!

View Source
var PodInheritWorkerMetaPrefix = []string{AnnoKeyEvictFailedMsg}
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: carbon.GroupName, Version: "v1"}

SchemeGroupVersion is group version used to register these objects

StripVersionLabelKeys represents label/annotation keys which will be ignored in version computation

View Source
var SubrsInheritanceMetaPrefix = []string{LabelServerlessAppId, LabelServerlessInstanceGroup, LabelServerlessAppName, LabelRuntimeAppName,
	"serverless.io/env-name", "app.hippo.io/appShortName", "app.hippo.io/roleShortName"}

Functions

func AddFinalizer

func AddFinalizer(rollingset *RollingSet, finalizer string)

AddFinalizer 添加Finalizer

func AddGangPartLabelHashKey

func AddGangPartLabelHashKey(labels map[string]string, partName string) error

AddGangPartLabelHashKey AddGangPartLabelHashKey

func AddGangPartSelectorHashKey

func AddGangPartSelectorHashKey(selector *metav1.LabelSelector, partName string) error

AddGangPartSelectorHashKey AddGangPartSelectorHashKey

func AddGangUniqueLabelHashKey

func AddGangUniqueLabelHashKey(labels map[string]string, replicaName string) error

AddGangUniqueLabelHashKey AddGangUniqueLabelHashKey

func AddGroupSelectorHashKey

func AddGroupSelectorHashKey(selector *metav1.LabelSelector, groupName string) error

AddGroupSelectorHashKey AddGroupSelectorHashKey

func AddGroupUniqueLabelHashKey

func AddGroupUniqueLabelHashKey(labels map[string]string, groupName string) error

AddGroupUniqueLabelHashKey AddGroupUniqueLabelHashKey

func AddReplicaSelectorHashKey

func AddReplicaSelectorHashKey(selector *metav1.LabelSelector, replicaName string) error

AddReplicaSelectorHashKey AddReplicaSelectorHashKey

func AddReplicaUniqueLabelHashKey

func AddReplicaUniqueLabelHashKey(labels map[string]string, replicaName string) error

AddReplicaUniqueLabelHashKey AddReplicaUniqueLabelHashKey

func AddRestartRecord

func AddRestartRecord(pod *corev1.Pod, worker *WorkerNode)

func AddRsSelectorHashKey

func AddRsSelectorHashKey(selector *metav1.LabelSelector, rsName string) error

AddRsSelectorHashKey AddRsSelectorHashKey

func AddRsUniqueLabelHashKey

func AddRsUniqueLabelHashKey(labels map[string]string, rsName string) error

AddRsUniqueLabelHashKey AddRsUniqueLabelHashKey

func AddSelectorHashKey

func AddSelectorHashKey(selector *metav1.LabelSelector, key, value string) error

AddSelectorHashKey AddSelectorHashKey

func AddSsSelectorHashKey

func AddSsSelectorHashKey(selector *metav1.LabelSelector, rsName string) error

AddSsSelectorHashKey AddSsSelectorHashKey

func AddSsUniqueLabelHashKey

func AddSsUniqueLabelHashKey(labels map[string]string, rsName string) error

AddSsUniqueLabelHashKey AddSsUniqueLabelHashKey

func AddSubrsShortUniqueKey

func AddSubrsShortUniqueKey(object metav1.Object, value string)

AddSubrsShortUniqueKey AddSubrsShortUniqueKey

func AddSubrsUniqueKey

func AddSubrsUniqueKey(object metav1.Object, value string) error

AddSubrsUniqueKey AddSubrsUniqueKey

func AddUniqueKey

func AddUniqueKey(object metav1.Object, key, value string) error

AddUniqueKey AddUniqueKey

func AddUniqueLabelHashKey

func AddUniqueLabelHashKey(labels map[string]string, key, value string) error

AddUniqueLabelHashKey AddUniqueLabelHashKey

func AddWorkerSelectorHashKey

func AddWorkerSelectorHashKey(selector *metav1.LabelSelector, workerName string) error

AddWorkerSelectorHashKey AddWorkerSelectorHashKey

func AddWorkerUniqueLabelHashKey

func AddWorkerUniqueLabelHashKey(labels map[string]string, workerName string) error

AddWorkerUniqueLabelHashKey AddWorkerUniqueLabelHashKey

func AggregateFraction

func AggregateFraction(fractions ...int32) (score int64)

AggregateFraction AggregateFraction

func AllocStatusScore

func AllocStatusScore(status AllocStatus) int32

AllocStatusScore compute the score of AllocStatus

func AppendWorkerCurrentLabel

func AppendWorkerCurrentLabel(lbls labels.Set) labels.Set

AppendWorkerCurrentLabel appends current worker label, used to select only current worker nodes.

func BackupOfPodNotEmpty

func BackupOfPodNotEmpty(worker *WorkerNode) bool

func BaseScoreOfWorker

func BaseScoreOfWorker(worker *WorkerNode) int64

BaseScoreOfWorker compute the score of a worker

func ClearObjectMeta

func ClearObjectMeta(meta *metav1.ObjectMeta)

ClearObjectMeta clear meta to init state

func CloneMap

func CloneMap(maps map[string]string) map[string]string

CloneMap Clone the given map and returns a new cloned map

func CloneSelector

func CloneSelector(selector *metav1.LabelSelector) *metav1.LabelSelector

CloneSelector Clones the given selector and returns a new cloned selector

func CompressShardTemplates

func CompressShardTemplates(shardgroup *ShardGroup)

func ComputeInstanceID

func ComputeInstanceID(needRestartAfterResourceChange bool, hippoPodSpec *HippoPodSpec) (string, map[string]string, error)

ComputeInstanceID ComputeInstanceID

func CopyContainersResource

func CopyContainersResource(current, target []corev1.Container, copyIP bool) error

CopyContainersResource copy resource fields 把目标资源copy到原pod上

func CopyCorePodResource

func CopyCorePodResource(podSpec *corev1.PodSpec, target *corev1.PodSpec, copyIP bool)

CopyCorePodResource copy resource fields 把目标资源copy到原pod上

func CopyHippoContainersResource

func CopyHippoContainersResource(current, target []HippoContainer, copyIP bool) error

CopyHippoContainersResource copy resource fields 把目标资源copy到原pod上

func CopyLabelsAnnos

func CopyLabelsAnnos(src metav1.Object, target metav1.Object, prefix []string)

func CopyPodResource

func CopyPodResource(hippoPodSpec *HippoPodSpec, target *HippoPodSpec, copyIP bool) error

CopyPodResource copy resource fields 把目标资源copy到原pod上

func CopySpecificKeys

func CopySpecificKeys(src map[string]string, dst map[string]string, keys []string)

func CopySunfireLabels

func CopySunfireLabels(src map[string]string, dst map[string]string)

func CopyWorkerAndReplicaLabels

func CopyWorkerAndReplicaLabels(mainMaps map[string]string, subMaps map[string]string) map[string]string

CopyWorkerAndReplicaLabels CopyWorkerAndReplicaLabels

func CouldDeletePod

func CouldDeletePod(worker *WorkerNode) bool

CouldDeletePod is pod could delete

func CreateWorkerLabels

func CreateWorkerLabels(labels map[string]string, replicaName, workerName string) map[string]string

CreateWorkerLabels CreateWorkerLabels

func CreateWorkerSelector

func CreateWorkerSelector(selector *metav1.LabelSelector, replicaName, workerName string) *metav1.LabelSelector

CreateWorkerSelector CreateWorkerSelector

func DaemonSetHostScore

func DaemonSetHostScore(worker *WorkerNode) int32

DaemonSetHostScore compute the score of host for daemonset

func DaemonsetScoreOfWorker

func DaemonsetScoreOfWorker(worker *WorkerNode) int64

DaemonsetScoreOfWorker compute the score of a worker for daemonset

func DecompressShardTemplates

func DecompressShardTemplates(shardgroup *ShardGroup) error

func EqualIgnoreHash

func EqualIgnoreHash(plan1, plan2 *VersionPlan) bool

EqualIgnoreHash returns true if two given podTemplateSpec are equal, ignoring the diff in value of Labels[pod-template-hash] We ignore pod-template-hash because:

  1. The hash result would be different upon podTemplateSpec API changes (e.g. the addition of a new field will cause the hash code to change)
  2. The deployment template won't have hash labels

func EscapeName

func EscapeName(name string) string

EscapeName for kube-apiserver

func ExceedRestartLimit

func ExceedRestartLimit(restartRecord string, limitCnt int) bool

func FixNewCreateLazyV3PodVersion

func FixNewCreateLazyV3PodVersion(object metav1.Object)

FixNewCreateLazyV3PodVersion FixNewCreateLazyV3PodVersion

func FixRolePvcVolumeMounts

func FixRolePvcVolumeMounts(pod *HippoPodTemplate)

FixRolePvcVolumeMounts FixRolePvcVolumeMounts

func FixSchedulerName

func FixSchedulerName(spec *HippoPodSpec)

FixSchedulerName FixSchedulerName

func FixUnifiedStorageVolumeMounts

func FixUnifiedStorageVolumeMounts(pod *HippoPodTemplate)

FixUnifiedStorageVolumeMounts FixUnifiedStorageVolumeMounts

func FixWorkerBecomeCurrentTime

func FixWorkerBecomeCurrentTime(current *WorkerNode)

func FixWorkerRole

func FixWorkerRole(current, backup *WorkerNode, deepcopy bool) (newCurrent *WorkerNode, newBackup *WorkerNode)

FixWorkerRole FixWorkerRole

func GenAppBatchID

func GenAppBatchID(app, group, batchID string) string

GenAppBatchID gen batch ID

func GenAppMetaID

func GenAppMetaID(app, group, role string) string

GenAppMetaID gen ID

func GenUniqIdentifier

func GenUniqIdentifier(workernode *WorkerNode) string

GenUniqIdentifier GenUniqIdentifier

func GenerateBufferName

func GenerateBufferName(grsName string) string

GenerateBufferName GenerateBufferName

func GenerateShardName

func GenerateShardName(shardGroupName string, shardKey string) string

GenerateShardName is used to generate a special unique shardName

func GenerateSubrsName

func GenerateSubrsName(grsName, shortSubrsName string) string

GenerateSubrsName GenerateSubrsName

func GetAnnotationValue

func GetAnnotationValue(object metav1.Object, key string) string

func GetAppChecksum

func GetAppChecksum(object metav1.Object) string

GetAppChecksum returns appChecksum label value.

func GetAppName

func GetAppName(object metav1.Object) string

GetAppName GetAppName

func GetAppStage

func GetAppStage(object metav1.Object) string

GetAppStage GetAppStage

func GetAppUnit

func GetAppUnit(object metav1.Object) string

GetAppUnit GetAppUnit

func GetBufferName

func GetBufferName(rollingSet *RollingSet) string

GetBufferName GetBufferName

func GetBufferSwapRecord

func GetBufferSwapRecord(object metav1.Object) string

func GetC2PodResVersion

func GetC2PodResVersion(object metav1.Object) string

GetC2PodResVersion GetC2PodResVersion

func GetC2PodVersion

func GetC2PodVersion(object metav1.Object) string

GetC2PodVersion GetPodVersion

func GetC2RoleName

func GetC2RoleName(object metav1.Object) string

GetC2RoleName GetC2RoleName

func GetCarbonJobID

func GetCarbonJobID(object metav1.Object) string

GetCarbonJobID GetCarbonJobID

func GetClusterName

func GetClusterName(object metav1.Object) string

GetClusterName GetClusterName

func GetCurrentPodUid

func GetCurrentPodUid(w *WorkerNode) string

func GetCurrentWorkerNodeV2

func GetCurrentWorkerNodeV2(workers []*WorkerNode, deepcopy bool) (*WorkerNode, *WorkerNode, bool)

GetCurrentWorkerNodeV2 getter

func GetCustomInfo

func GetCustomInfo(versionPlan *VersionPlan) string

GetCustomInfo get custominfo

func GetDefaultPodVersion

func GetDefaultPodVersion() string

GetDefaultPodVersion default pod version

func GetDefaultSchedulerName

func GetDefaultSchedulerName() string

GetDefaultSchedulerName GetDefaultSchedulerName

func GetDeletionCost

func GetDeletionCost(replica *Replica) int64

func GetEvictFailedMsg

func GetEvictFailedMsg(object metav1.Object) string

GetEvictFailedMsg GetEvictFailedMsg

func GetEviction

func GetEviction(object metav1.Object) string

GetEviction GetEviction

func GetExclusiveLableAnno

func GetExclusiveLableAnno(object metav1.Object) string

GetExclusiveLableAnno GetExclusiveLableAnno

func GetExclusiveMode

func GetExclusiveMode(object metav1.Object) string

GetExclusiveMode GetExclusiveMode

func GetGangID

func GetGangID(object metav1.Object) string

GetGangID GetGangID

func GetGangInfo

func GetGangInfo(object metav1.Object) string

GetGangInfo GetGangInfo

func GetGangPartName

func GetGangPartName(object metav1.Object) string

GetGangPartName GetGangPartName

func GetGangPlan

func GetGangPlan(object metav1.Object) string

GetGangPlan GetGangPlan

func GetGroupName

func GetGroupName(object metav1.Object) string

GetGroupName GetGroupName

func GetGroupStatus

func GetGroupStatus(g *ShardGroup) string

GetGroupStatus get status description

func GetGroupVersionStatusMap

func GetGroupVersionStatusMap(replicaSet []*Replica) (int64, map[string]*rollalgorithm.VersionStatus)

GetGroupVersionStatusMap 返回groupverison的状态

func GetHealthMetas

func GetHealthMetas(worker *WorkerNode) map[string]string

GetHealthMetas get health metas

func GetInactiveInterpose

func GetInactiveInterpose(object metav1.Object) (labels, annotations map[string]string)

GetInactiveInterpose GetInactiveInterpose

func GetInactiveSpreadReplicas

func GetInactiveSpreadReplicas(object metav1.Object) (active, inactive int32)

GetInactiveSpreadReplicas GetInactiveSpreadReplicas

func GetInstanceGroup

func GetInstanceGroup(object metav1.Object) string

GetInstanceGroup GetInstanceGroup

func GetLabelAnnoValue

func GetLabelAnnoValue(object metav1.Object, key string) string

GetLabelAnnoValue see issue #101090

func GetLabelValue

func GetLabelValue(object metav1.Object, key string) string

GetLabelValue GetLabelValue

func GetLaunchSignature

func GetLaunchSignature(object metav1.Object) int64

GetLaunchSignature GetLaunchSignature

func GetMigratedFromSubrs

func GetMigratedFromSubrs(object metav1.Object) string

GetMigratedFromSubrs GetMigratedFromSubrs

func GetNonVersionedKeys

func GetNonVersionedKeys() (mapset.Set, error)

func GetObjectBaseScopes

func GetObjectBaseScopes(object metav1.Object, extends ...string) []string

GetObjectBaseScopes GetObjectBaseScopes

func GetObjectExtendScopes

func GetObjectExtendScopes(object metav1.Object, extends ...string) []string

GetObjectExtendScopes GetObjectExtendScopes

func GetObjectScaleScopes

func GetObjectScaleScopes(object metav1.Object, extends ...string) []string

GetObjectScaleScopes ..

func GetPackageChecksum

func GetPackageChecksum(object metav1.Object) string

GetPackageChecksum GetPackageChecksum

func GetPairWorkerName

func GetPairWorkerName(currWorkerName string) string

func GetPodName

func GetPodName(w *WorkerNode) (name string, err error)

GetPodName get the pod name of worker

func GetPodRecycleMode

func GetPodRecycleMode(pod *corev1.Pod) string

GetPodRecycleMode get pod recycle mod

func GetPodSlaveIP

func GetPodSlaveIP(pod *corev1.Pod) string

GetPodSlaveIP GetPodSlaveIP

func GetPodSlotID

func GetPodSlotID(pod *corev1.Pod) (int32, bool)

GetPodSlotID GetPodSlotID

func GetPodStatus

func GetPodStatus(r *corev1.Pod) string

GetPodStatus get status description

func GetPodStatusFromCondition

func GetPodStatusFromCondition(pod *corev1.Pod, conditionType corev1.PodConditionType) corev1.ConditionStatus

GetPodStatusFromCondition GetPodStatusFromCondition

func GetPodVersion

func GetPodVersion(object metav1.Object) string

GetPodVersion GetPodVersion

func GetPriorityV1

func GetPriorityV1(object metav1.Object) int32

GetPriorityV1 GetPriorityV1

func GetQuotaID

func GetQuotaID(object metav1.Object) string

GetQuotaID GetQuotaID

func GetReplaceNodeVersion

func GetReplaceNodeVersion(object metav1.Object) string

GetReplaceNodeVersion GetReplaceNodeVersion

func GetReplicaID

func GetReplicaID(object metav1.Object) string

GetReplicaID GetReplicaID

func GetReplicaKey

func GetReplicaKey(obj metav1.Object) (string, bool)

func GetReplicaPoolType

func GetReplicaPoolType(replica *Replica) string

func GetReplicaReferWorkerNums

func GetReplicaReferWorkerNums(replica *Replica) int

GetReplicaReferWorkerNums 获取replica上refer worker数量

func GetReplicaStandbyHours

func GetReplicaStandbyHours(replica *Replica) []int64

GetReplicaStandbyHours get standby hours

func GetReplicaStatus

func GetReplicaStatus(r *Replica) string

GetReplicaStatus get status description

func GetReportRsID

func GetReportRsID(object metav1.Object) string

GetReportRsID 用来汇报controller指标中rollingset key的value

func GetRequirementID

func GetRequirementID(object metav1.Object) string

GetRequirementID GetRequirementID

func GetResVersion

func GetResVersion(name string, hippoPodSpec HippoPodSpec, ins ...interface{}) (string, error)

GetResVersion GetResVersion

func GetRoleName

func GetRoleName(object metav1.Object) string

GetRoleName GetRoleName

func GetRoleNameAndName

func GetRoleNameAndName(object metav1.Object) string

GetRoleNameAndName GetRoleNameAndName

func GetRolePvcName

func GetRolePvcName(object metav1.Object) string

GetRolePvcName GetRolePvcName

func GetRollingSetStatus

func GetRollingSetStatus(r *RollingSet) string

GetRollingSetStatus get status description

func GetRollingsetNameHashs

func GetRollingsetNameHashs(group *ShardGroup) map[string]bool

GetRollingsetNameHashs GetRollingsetNameHashs

func GetRsID

func GetRsID(object metav1.Object) string

GetRsID GetRsID

func GetRsName

func GetRsName(worker *WorkerNode) string

func GetRsSelector

func GetRsSelector(rsName string) labels.Selector

GetRsSelector GetRsSelector

func GetRsStringSelector

func GetRsStringSelector(rsName string) string

GetRsStringSelector GetRsStringSelector

func GetSSPodOwnerKey

func GetSSPodOwnerKey(object metav1.Object) string

GetSSPodOwnerKey GetSSPodOwnerKey

func GetServiceVersion

func GetServiceVersion(object metav1.Object) string

GetServiceVersion GetServiceVersion

func GetShardGroupID

func GetShardGroupID(object metav1.Object) string

GetShardGroupID GetShardGroupID

func GetSpotTargetFromAnnotation

func GetSpotTargetFromAnnotation(rs *RollingSet) int

func GetSsID

func GetSsID(object metav1.Object) string

GetSsID GetSsID

func GetSubObjectBaseScopes

func GetSubObjectBaseScopes(object metav1.Object, extends ...string) []string

GetSubObjectBaseScopes GetSubObjectBaseScopes

func GetSubObjectExtendScopes

func GetSubObjectExtendScopes(object metav1.Object, extends ...string) []string

GetSubObjectExtendScopes GetSubObjectExtendScopes

func GetSubrs

func GetSubrs(object metav1.Object) string

GetSubrs GetSubrs

func GetSubrsMetas

func GetSubrsMetas(rs *RollingSet) string

func GetSubrsShortUniqueKey

func GetSubrsShortUniqueKey(object metav1.Object) string

GetSubrsShortUniqueKey GetSubrsShortUniqueKey

func GetSyncMetaPrefix

func GetSyncMetaPrefix() []string

func GetTemplateAnnotationSet

func GetTemplateAnnotationSet(template *GeneralTemplate) labels.Set

GetTemplateAnnotationSet copy annotations

func GetTemplateFinalizers

func GetTemplateFinalizers(template *GeneralTemplate) []string

GetTemplateFinalizers copy finalizers

func GetTemplateLabelSet

func GetTemplateLabelSet(template *GeneralTemplate) labels.Set

GetTemplateLabelSet copy labels

func GetWorkerDeletionCost

func GetWorkerDeletionCost(worker *WorkerNode) int64

func GetWorkerNameFromPod

func GetWorkerNameFromPod(obj metav1.Object) (name string, err error)

GetWorkerNameFromPod get the worker name from pod info

func GetWorkerOwnerKey

func GetWorkerOwnerKey(object metav1.Object) string

GetWorkerOwnerKey GetWorkerOwnerKey

func GetWorkerReplicaName

func GetWorkerReplicaName(w *WorkerNode) string

GetWorkerReplicaName gets replica name for a worker node

func GetWorkerResyncTime

func GetWorkerResyncTime(worker *WorkerNode) int64

GetWorkerResyncTime if worker is not IsWorkerLongtimeNotMatch nor IsWorkerLongtimeNotReady, get the min timeout time

func GetWorkerSilenceTimeout

func GetWorkerSilenceTimeout(worker *WorkerNode) int64

GetWorkerSilenceTimeout GetWorkerSilenceTimeout

func GetWorkerStandbyHours

func GetWorkerStandbyHours(worker *WorkerNode) []int64

func GetWorkerStatus

func GetWorkerStatus(r *WorkerNode) string

GetWorkerStatus get status description

func GetWorkersResyncTime

func GetWorkersResyncTime(workers []*WorkerNode) int64

GetWorkersResyncTime get the min not zero timeout of workers

func GetZoneName

func GetZoneName(object metav1.Object) string

GetZoneName GetZoneName

func HealthScore

func HealthScore(status HealthStatus) int32

HealthScore compute the score of HealthStatus

func IfWorkerServiceMetasRecovered

func IfWorkerServiceMetasRecovered(worker *WorkerNode) bool

IfWorkerServiceMetasRecovered IfWorkerServiceMetasRecovered

func InSilence

func InSilence(w *WorkerNode) bool

InSilence get the pod name of worker

func InStandby2Active

func InStandby2Active(w *WorkerNode) bool

InStandby2Active in

func InitAnnotationsLabels

func InitAnnotationsLabels(meta *metav1.ObjectMeta)

InitAnnotationsLabels InitAnnotationsLabels

func InitFlags

func InitFlags(flagset *pflag.FlagSet)

InitFlags is for explicitly initializing the flags.

func InitIfNil

func InitIfNil(m map[string]string) map[string]string

func InitWorkerNode

func InitWorkerNode(worker *WorkerNode)

InitWorkerNode 初始化默认值

func InitWorkerScheduleTimeout

func InitWorkerScheduleTimeout(worker *WorkerSchedulePlan)

InitWorkerScheduleTimeout InitWorkerScheduleTimeout

func InjectMetas

func InjectMetas(meta *metav1.ObjectMeta)

InjectMetas InjectMetas

func IsAdminRole

func IsAdminRole(role string) bool

IsAdminRole IsAdminRole

func IsAllWorkersReleased

func IsAllWorkersReleased(workers []*WorkerNode) bool

IsAllWorkersReleased means if all workers of this replica is released

func IsAsiNaming

func IsAsiNaming(rs *RollingSet) bool

func IsAsiPod

func IsAsiPod(meta *metav1.ObjectMeta) bool

IsAsiPod IsAsiPod

func IsBackupWorker

func IsBackupWorker(worker *WorkerNode) bool

IsBackupWorker judge is the worker is current worker preliminarily

func IsBelowMinHealth

func IsBelowMinHealth(rs *RollingSet) bool

func IsBizPod

func IsBizPod(meta *metav1.ObjectMeta) bool

func IsBufferRollingSet

func IsBufferRollingSet(rollingSet *RollingSet) bool

IsBufferRollingSet IsBufferRollingSet

func IsBufferRollingSetName

func IsBufferRollingSetName(rsName string) bool

IsBufferRollingSetName IsBufferRollingSetName

func IsC2Scheduler

func IsC2Scheduler(object metav1.Object) bool

IsC2Scheduler IsC2Scheduler

func IsColdStandbyWorker

func IsColdStandbyWorker(worker *WorkerNode) bool

IsColdStandbyWorker IsColdStandbyWorker

func IsCurrentHotStandbyWorker

func IsCurrentHotStandbyWorker(worker *WorkerNode) bool

IsCurrentHotStandbyWorker current hot

func IsCurrentWorker

func IsCurrentWorker(worker *WorkerNode) bool

IsCurrentWorker judge is the worker is current worker preliminarily

func IsDaemonPod

func IsDaemonPod(podSpec corev1.PodSpec) bool

IsDaemonPod IsDaemonPod

func IsDaemonSetWorker

func IsDaemonSetWorker(worker *WorkerNode) bool

IsDaemonSetWorker is this worker for daemonset

func IsDaemonWorker

func IsDaemonWorker(worker *WorkerNode) bool

IsDaemonWorker IsDaemonWorker

func IsGangMainPart

func IsGangMainPart(object metav1.Object) bool

IsGangMainPart IsGangMainPart

func IsGeneralServiceReady

func IsGeneralServiceReady(worker *WorkerNode) bool

func IsGroupRollingSet

func IsGroupRollingSet(rollingSet *RollingSet) bool

IsGroupRollingSet IsGroupRollingSet

func IsHealthCheckDone

func IsHealthCheckDone(worker *WorkerNode) bool

IsHealthCheckDone IsHealthCheckDone

func IsHotStandbyWorker

func IsHotStandbyWorker(worker *WorkerNode) bool

IsHotStandbyWorker IsHotStandbyWorker

func IsInactiveWorker

func IsInactiveWorker(worker *WorkerNode) bool

IsInactiveWorker IsInactiveWorker

func IsLazyV3

func IsLazyV3(object metav1.Object) bool

IsLazyV3 IsLazyV3

func IsNetworkChanged

func IsNetworkChanged(before, after *corev1.Pod) bool

IsNetworkChanged IsNetworkChanged

func IsNonVersionedKeysMatch

func IsNonVersionedKeysMatch(src metav1.Object, target metav1.Object, keys mapset.Set) bool

func IsPodCreateByC2

func IsPodCreateByC2(pod *corev1.Pod) bool

IsPodCreateByC2 IsPodCreateByC2

func IsPodHasTerminatedContainer

func IsPodHasTerminatedContainer(pod *corev1.Pod) (bool, bool)

IsPodHasTerminatedContainer if a container of pod is terminated return true

func IsPodHasWaitingContainer

func IsPodHasWaitingContainer(pod *corev1.Pod) bool

IsPodHasWaitingContainer if a container of pod is waiting return true

func IsPodInactive

func IsPodInactive(pod *corev1.Pod) bool

IsPodInactive IsPodInactive

func IsPodPreInactive

func IsPodPreInactive(pod *corev1.Pod) bool

IsPodPreInactive IsPodPreInactive

func IsPodPriorityMid

func IsPodPriorityMid(priority int32) bool

IsPodPriorityMid mid pod

func IsPodPriorityOffline

func IsPodPriorityOffline(priority int32) bool

IsPodPriorityOffline offline pod

func IsPodPriorityOnline

func IsPodPriorityOnline(priority int32) bool

IsPodPriorityOnline online pod

func IsPodPrioritySys

func IsPodPrioritySys(priority int32) bool

IsPodPrioritySys sys pod

func IsPodReclaimed

func IsPodReclaimed(pod *corev1.Pod) bool

IsPodReclaimed IsPodReclaimed

func IsQuickOnline

func IsQuickOnline(object metav1.Object) bool

IsQuickOnline IsQuickOnline

func IsQuotaNotEnough

func IsQuotaNotEnough(w *WorkerNode) bool

func IsRejectByWebhook

func IsRejectByWebhook(err error) bool

IsRejectByWebhook IsRejectByWebhook

func IsReplicaAllocReleasing

func IsReplicaAllocReleasing(replica *Replica) bool

IsReplicaAllocReleasing get current state

func IsReplicaAssigned

func IsReplicaAssigned(replica *Replica) bool

IsReplicaAssigned get current state

func IsReplicaAvailable

func IsReplicaAvailable(replica *Replica) bool

IsReplicaAvailable means is the replica service is avaiable

func IsReplicaComplete

func IsReplicaComplete(replica *Replica) bool

IsReplicaComplete get current state

func IsReplicaDependencyReady

func IsReplicaDependencyReady(replica *Replica) bool

IsReplicaDependencyReady IsReplicaDependencyReady

func IsReplicaEmpty

func IsReplicaEmpty(replica *Replica) bool

IsReplicaEmpty get current state

func IsReplicaHealth

func IsReplicaHealth(replica *Replica) bool

IsReplicaHealth means is the replica service is avaiable

func IsReplicaLost

func IsReplicaLost(replica *Replica) bool

IsReplicaLost get current state

func IsReplicaNoRefers

func IsReplicaNoRefers(replica *Replica) bool

IsReplicaNoRefers 判断是否没有引用

func IsReplicaNotInited

func IsReplicaNotInited(replica *Replica) bool

IsReplicaNotInited IsReplicaNotInited

func IsReplicaOfflining

func IsReplicaOfflining(replica *Replica) bool

IsReplicaOfflining get current state

func IsReplicaOnStandByResourcePool

func IsReplicaOnStandByResourcePool(replica *Replica) bool

IsReplicaOnStandByResourcePool IsReplicaOnStandByResourcePool

func IsReplicaProcessReady

func IsReplicaProcessReady(replica *Replica) bool

IsReplicaProcessReady if service process ready

func IsReplicaReleased

func IsReplicaReleased(replica *Replica) bool

IsReplicaReleased get current state

func IsReplicaReleasing

func IsReplicaReleasing(replica *Replica) bool

IsReplicaReleasing get current state

func IsReplicaServiceReady

func IsReplicaServiceReady(replica *Replica) (int64, bool)

IsReplicaServiceReady IsReplicaServiceReady

func IsReplicaUnAssigned

func IsReplicaUnAssigned(replica *Replica) bool

IsReplicaUnAssigned get current state

func IsResVersionMatch

func IsResVersionMatch(worker *WorkerNode) bool

IsResVersionMatch the worker is the current version

func IsRollingSetGracefully

func IsRollingSetGracefully(rs *RollingSet) bool

IsRollingSetGracefully IsRollingSetGracefully

func IsRrResourceUpdating

func IsRrResourceUpdating(worker *WorkerNode) bool

IsRrResourceUpdating get the pod name of worker

func IsServerless

func IsServerless(rs *RollingSet) bool

func IsServiceReadyForMinTime

func IsServiceReadyForMinTime(worker *WorkerNode) (int64, bool)

IsServiceReadyForMinTime IsServiceReadyForMinTime

func IsSilenceNode

func IsSilenceNode(w *WorkerNode) bool

IsSilenceNode get the pod name of worker

func IsSkylineChanged

func IsSkylineChanged(before, after *corev1.Pod) bool

IsSkylineChanged IsSkylineChanged

func IsStandByWorkerComplete

func IsStandByWorkerComplete(worker *WorkerNode) bool

IsStandByWorkerComplete IsStandByWorkerComplete

func IsStandbyReplica

func IsStandbyReplica(replica *Replica) bool

IsStandbyReplica is standby

func IsStandbyWorker

func IsStandbyWorker(worker *WorkerNode) bool

IsStandbyWorker IsStandbyWorker

func IsStandbyWorkerMode

func IsStandbyWorkerMode(workerMode WorkerModeType) bool

IsStandbyWorkerMode IsStandbyWorkerMode

func IsSubRollingSet

func IsSubRollingSet(rollingSet *RollingSet) bool

IsSubRollingSet IsSubRollingSet

func IsSubrsEnable

func IsSubrsEnable(rs *RollingSet) bool

func IsV25

func IsV25(object metav1.Object) bool

IsV25 IsV25

func IsV3

func IsV3(object metav1.Object) bool

IsV3 IsV3

func IsVersionInnerMatch

func IsVersionInnerMatch(ver1, ver2 string) bool

func IsVersionMatch

func IsVersionMatch(worker *WorkerNode) bool

IsVersionMatch the worker is the current version

func IsWorkerAssigned

func IsWorkerAssigned(worker *WorkerNode) bool

IsWorkerAssigned means is worker unassigned

func IsWorkerComplete

func IsWorkerComplete(worker *WorkerNode) bool

IsWorkerComplete means is a worker status is ok completely

func IsWorkerDead

func IsWorkerDead(worker *WorkerNode) bool

IsWorkerDead ,process and health check status

func IsWorkerDependencyReady

func IsWorkerDependencyReady(worker *WorkerNode) bool

IsWorkerDependencyReady IsWorkerDependencyReady

func IsWorkerEmpty

func IsWorkerEmpty(worker *WorkerNode) bool

IsWorkerEmpty judge is the worker is allocated

func IsWorkerEntityAlloced

func IsWorkerEntityAlloced(worker *WorkerNode) bool

IsWorkerEntityAlloced judge is the worker entity is allocated

func IsWorkerFalied

func IsWorkerFalied(worker *WorkerNode) bool

IsWorkerFalied means is worker lost

func IsWorkerGracefully

func IsWorkerGracefully(worker *WorkerNode) bool

IsWorkerGracefully means is worker UpdatingGracefully field is nil or true

func IsWorkerHaveBeenUnassignException

func IsWorkerHaveBeenUnassignException(worker *WorkerNode) bool

IsWorkerHaveBeenUnassignException worker是否分配异常(未调度除外)

func IsWorkerHealth

func IsWorkerHealth(worker *WorkerNode) bool

IsWorkerHealth , process and health check status

func IsWorkerHealthInfoReady

func IsWorkerHealthInfoReady(worker *WorkerNode) bool

IsWorkerHealthInfoReady version updated and health

func IsWorkerHealthMatch

func IsWorkerHealthMatch(worker *WorkerNode) bool

IsWorkerHealthMatch worker health for this version

func IsWorkerInWarmup

func IsWorkerInWarmup(worker *WorkerNode) bool

IsWorkerInWarmup IsWorkerInWarmup

func IsWorkerInnerVerMatch

func IsWorkerInnerVerMatch(w *WorkerNode) bool

func IsWorkerIrrecoverable

func IsWorkerIrrecoverable(worker *WorkerNode) bool

IsWorkerIrrecoverable IsWorkerIrrecoverable

func IsWorkerLatestVersionAvailable

func IsWorkerLatestVersionAvailable(worker *WorkerNode) bool

IsWorkerLatestVersionAvailable means is the worker service is avaiable

func IsWorkerLongtimeNotMatch

func IsWorkerLongtimeNotMatch(worker *WorkerNode, targetVersion string) bool

IsWorkerLongtimeNotMatch means is worker resource not match for too long time, that exceed the limit

func IsWorkerLongtimeNotReady

func IsWorkerLongtimeNotReady(worker *WorkerNode) bool

IsWorkerLongtimeNotReady means is worker process not ready for too long time, that exceed the limit

func IsWorkerLongtimeNotSchedule

func IsWorkerLongtimeNotSchedule(worker *WorkerNode) bool

IsWorkerLongtimeNotSchedule means is worker resource not match for too long time, that exceed the limit

func IsWorkerLost

func IsWorkerLost(worker *WorkerNode) bool

IsWorkerLost means is worker lost

func IsWorkerMatch

func IsWorkerMatch(worker *WorkerNode) bool

IsWorkerMatch means is service status is AVAILABLE

func IsWorkerModeMisMatch

func IsWorkerModeMisMatch(worker *WorkerNode) bool

IsWorkerModeMisMatch means worker mode changed

func IsWorkerNodeUseUnifiedStorageVolume

func IsWorkerNodeUseUnifiedStorageVolume(worker *WorkerNode) bool

func IsWorkerNotPublishToCM2

func IsWorkerNotPublishToCM2(worker *WorkerNode) bool

IsWorkerNotPublishToCM2 IsWorkerNotPublishToCM2

func IsWorkerNotStarted

func IsWorkerNotStarted(worker *WorkerNode) bool

IsWorkerNotStarted just is worker not started

func IsWorkerOfflined

func IsWorkerOfflined(worker *WorkerNode) bool

IsWorkerOfflined means is service status is UNAVAILABLE and has no conditions

func IsWorkerOfflining

func IsWorkerOfflining(worker *WorkerNode) bool

IsWorkerOfflining means is worker offlining

func IsWorkerOnStandByResourcePool

func IsWorkerOnStandByResourcePool(worker *WorkerNode) bool

IsWorkerOnStandByResourcePool IsWorkerOnStandByResourcePool

func IsWorkerOnline

func IsWorkerOnline(worker *WorkerNode) bool

IsWorkerOnline means is worker online field is nil or true

func IsWorkerPending

func IsWorkerPending(worker *WorkerNode) bool

IsWorkerPending means is worker process pending

func IsWorkerProcessLongtimeNotMatch

func IsWorkerProcessLongtimeNotMatch(worker *WorkerNode) bool

IsWorkerProcessLongtimeNotMatch means is worker process not match for too long time, that exceed the limit

func IsWorkerProcessLongtimeNotReady

func IsWorkerProcessLongtimeNotReady(worker *WorkerNode) bool

IsWorkerProcessLongtimeNotReady means is worker process not ready for too long time, that exceed the limit

func IsWorkerProcessReady

func IsWorkerProcessReady(worker *WorkerNode) bool

IsWorkerProcessReady if service process ready

func IsWorkerReady

func IsWorkerReady(worker *WorkerNode) bool

IsWorkerReady return the ready status provide by allocator

func IsWorkerReclaiming

func IsWorkerReclaiming(worker *WorkerNode) bool

IsWorkerReclaiming means is worker reclaim

func IsWorkerReleased

func IsWorkerReleased(worker *WorkerNode) bool

IsWorkerReleased means is worker alloc status is in released

func IsWorkerReleasing

func IsWorkerReleasing(worker *WorkerNode) bool

IsWorkerReleasing means is worker alloc status is in releasing

func IsWorkerResVersionMisMatch

func IsWorkerResVersionMisMatch(worker *WorkerNode) bool

IsWorkerResVersionMisMatch means cur resversion and target resversion is not same

func IsWorkerRollback

func IsWorkerRollback(w *WorkerNode) bool

func IsWorkerRowComplete

func IsWorkerRowComplete(worker *WorkerNode) bool

func IsWorkerRunning

func IsWorkerRunning(worker *WorkerNode) bool

IsWorkerRunning means is worker process running

func IsWorkerServiceMatch

func IsWorkerServiceMatch(worker *WorkerNode) bool

IsWorkerServiceMatch means is service status match plan

func IsWorkerServiceOffline

func IsWorkerServiceOffline(worker *WorkerNode) bool

IsWorkerServiceOffline if offline service

func IsWorkerServiceReady

func IsWorkerServiceReady(worker *WorkerNode) (int64, bool)

IsWorkerServiceReady IsWorkerServiceReady

func IsWorkerToDelete

func IsWorkerToDelete(worker *WorkerNode) bool

IsWorkerToDelete means is worker to delete

func IsWorkerToRelease

func IsWorkerToRelease(worker *WorkerNode) bool

IsWorkerToRelease means is worker releasing

func IsWorkerTypeReady

func IsWorkerTypeReady(worker *WorkerNode) bool

IsWorkerTypeReady 心跳业务服务正常

func IsWorkerUnAssigned

func IsWorkerUnAssigned(worker *WorkerNode) bool

IsWorkerUnAssigned means is the worker is unassigned

func IsWorkerUnAvaliable

func IsWorkerUnAvaliable(worker *WorkerNode) bool

IsWorkerUnAvaliable means is service status is UNAVAILABLE

func IsWorkerUnpublished

func IsWorkerUnpublished(worker *WorkerNode) bool

IsWorkerUnpublished IsWorkerUnpublished

func IsWorkerUnserviceable

func IsWorkerUnserviceable(worker *WorkerNode) bool

IsWorkerUnserviceable IsWorkerUnserviceable

func IsWorkerUpdateMatch

func IsWorkerUpdateMatch(worker *WorkerNode) bool

func IsWorkerUpdateReady

func IsWorkerUpdateReady(worker *WorkerNode) bool

func IsWorkerVersionMisMatch

func IsWorkerVersionMisMatch(worker *WorkerNode) bool

IsWorkerVersionMisMatch means cur version and target version is not same

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns back a Group qualified GroupKind

func LabelValueHash

func LabelValueHash(v string, enable bool) string

LabelValueHash hash the label value if it validates failed

func MakeNameLegal

func MakeNameLegal(name string) string

MakeNameLegal MakeNameLegal

func MapCopy

func MapCopy(src map[string]string, dst map[string]string)

MapCopy MapCopy

func MarshalStablePodStatus

func MarshalStablePodStatus(worker *WorkerNode) string

func MegerContainersRess

func MegerContainersRess(containers []ContainerInstanceField) corev1.ResourceRequirements

MegerContainersRess MegerContainersRess

func MergeMap

func MergeMap(from map[string]string, to map[string]string) map[string]string

MergeMap merge all kvs to target map

func NeedCreatePool

func NeedCreatePool(rs *RollingSet, spec *PoolSpec, status *PoolStatus) bool

func NeedDeletePool

func NeedDeletePool(rs *RollingSet, spec *PoolSpec, status *PoolStatus) bool

func NeedReclaimByService

func NeedReclaimByService(worker *WorkerNode) bool

func NeedRestartAfterResourceChange

func NeedRestartAfterResourceChange(versionPlan *VersionPlan) bool

NeedRestartAfterResourceChange NeedRestartAfterResourceChange

func NeedRollingAfterResourceChange

func NeedRollingAfterResourceChange(versionPlan *VersionPlan) bool

NeedRollingAfterResourceChange NeedRollingAfterResourceChange

func NeedUpdateGracefully

func NeedUpdateGracefully(service *ServicePublisher) bool

NeedUpdateGracefully is this service need updated gracefully

func NeedUpdatePool

func NeedUpdatePool(rs *RollingSet, spec *PoolSpec, status *PoolStatus) bool

func NeedWarmup

func NeedWarmup(worker *WorkerNode) bool

NeedWarmup NeedWarmup

func OverrideMap

func OverrideMap(base, prefer map[string]string) map[string]string

func PatchMap

func PatchMap(mainMaps map[string]string, subMaps map[string]string, keys ...string) map[string]string

PatchMap merge mainLabels and keys of sub labels to new labels

func PatchObject

func PatchObject(kind string, object metav1.Object) error

func PhaseScore

func PhaseScore(status WorkerPhase) int32

PhaseScore compute the score of WorkerPhase

func PodIsEvicted

func PodIsEvicted(podStatus v1.PodStatus) bool

PodIsEvicted returns true if the reported pod status is due to an eviction.

func PopSliceElement

func PopSliceElement(elements []string, element string) ([]string, bool)

func PredictInfoEqual

func PredictInfoEqual(before, after map[int64]int64) bool

func RecordPodReadyTime

func RecordPodReadyTime(worker *WorkerNode)

RecordPodReadyTime worker

func RecordWorkerReadyTime

func RecordWorkerReadyTime(worker *WorkerNode)

RecordWorkerReadyTime worker

func ReleaseWorker

func ReleaseWorker(worker *WorkerNode, prohibit bool)

ReleaseWorker ReleaseWorker

func RemoveEvictFailedMsg

func RemoveEvictFailedMsg(object metav1.Object)

RemoveEvictFailedMsg RemoveEvictFailedMsg

func RemoveFinalizer

func RemoveFinalizer(rollingset *RollingSet, finalizer string)

RemoveFinalizer 移除Finalizer

func RemoveLabelsAnnos

func RemoveLabelsAnnos(meta metav1.Object, prefix []string)

func ReplicaResourcePoolScore

func ReplicaResourcePoolScore(replica *Replica) int32

func ReplicaWorkModeScore

func ReplicaWorkModeScore(replica *Replica) int32

ReplicaWorkModeScore compute the score of workModeType

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

func ResourceNameHash

func ResourceNameHash(name string) (string, error)

ResourceNameHash hash resource name, NOTE the name is valid by k8s name conversation see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/

func ScoreOfWorker

func ScoreOfWorker(worker *WorkerNode) int64

ScoreOfWorker compute the score of a worker

func ServiceScore

func ServiceScore(worker *WorkerNode) int32

ServiceScore ServiceScore

func ServiceStatusScore

func ServiceStatusScore(status ServiceStatus) int32

ServiceStatusScore compute the score of ServiceStatus

func SetAnnoGroupName

func SetAnnoGroupName(object metav1.Object, groupName string)

SetAnnoGroupName set group name

func SetAntMetas

func SetAntMetas(meta *metav1.ObjectMeta)

SetAntMetas SetAntMetas

func SetAppChecksum

func SetAppChecksum(object metav1.Object, appChecksum string)

SetAppChecksum set app/admin checksum to a resource. NOTE: Its admin-manager responsibility to generate app checksum when it deploy admin on k8s.

func SetAppName

func SetAppName(object metav1.Object, appName string)

SetAppName SetAppName

func SetAppSelector

func SetAppSelector(selector *metav1.LabelSelector, appName string) error

SetAppSelector SetAppSelector

func SetBackupPod

func SetBackupPod(object metav1.Object, uid string)

SetBackupPod SetBackupPod

func SetBadReason

func SetBadReason(w *WorkerNode, reason BadReasonType)

SetBadReason SetBadReason

func SetBufferSwapRecord

func SetBufferSwapRecord(object metav1.Object, value string)

func SetC2PodResVersion

func SetC2PodResVersion(object metav1.Object, version string)

SetC2PodResVersion SetC2PodResVersion

func SetC2PodVersion

func SetC2PodVersion(object metav1.Object, version string)

SetC2PodVersion SetC2PodVersion

func SetC2Scheduler

func SetC2Scheduler(object metav1.Object, isC2Scheduler bool)

SetC2Scheduler SetC2Scheduler

func SetClusterName

func SetClusterName(object metav1.Object, clusterName string)

SetClusterName SetClusterName

func SetClusterSelector

func SetClusterSelector(selector *metav1.LabelSelector, clusterName string) error

SetClusterSelector SetClusterSelector

func SetDefaultObjectValidLabel

func SetDefaultObjectValidLabel(meta metav1.Object, k, v string)

SetDefaultObjectValidLabel set label if the value is valid and not exist, otherwise write the raw value in the annotation if not exist

func SetDefaultPodVersion

func SetDefaultPodVersion(meta *metav1.ObjectMeta)

SetDefaultPodVersion SetDefaultPodVersion

func SetDefaultVipPodVersion

func SetDefaultVipPodVersion(meta *metav1.ObjectMeta)

SetDefaultVipPodVersion SetDefaultVipPodVersion

func SetEvictFailedMsg

func SetEvictFailedMsg(object metav1.Object, state string)

SetEvictFailedMsg SetEvictFailedMsg

func SetEviction

func SetEviction(object metav1.Object)

SetEviction SetEviction

func SetExclusiveLableAnno

func SetExclusiveLableAnno(object metav1.Object, exclusive string)

SetExclusiveLableAnno SetExclusiveLableAnno

func SetGangInfo

func SetGangInfo(object metav1.Object, info string)

SetGangInfo SetGangInfo

func SetGangMainPart

func SetGangMainPart(object metav1.Object)

SetGangMainPart SetGangMainPart

func SetGangPartName

func SetGangPartName(object metav1.Object, part string)

SetGangPartName SetGangPartName

func SetGangPlan

func SetGangPlan(object metav1.Object, plan string)

SetGangPlan SetGangPlan

func SetGroupName

func SetGroupName(object metav1.Object, groupName string)

SetGroupName SetGroupName

func SetGroupSelector

func SetGroupSelector(selector *metav1.LabelSelector, groupName string) error

SetGroupSelector SetGroupSelector

func SetGroupsSelector

func SetGroupsSelector(selector *metav1.LabelSelector, groupIDs ...string) error

SetGroupsSelector SetGroupsSelector

func SetHashAppSelector

func SetHashAppSelector(selector *metav1.LabelSelector, appName string) error

SetHashAppSelector use LabelKeyAppNameHash

func SetHippoLabelSelector

func SetHippoLabelSelector(selector *metav1.LabelSelector, key string, value string) error

SetHippoLabelSelector SetHippoLabelSelector

func SetIfEmptyAndReturnOld

func SetIfEmptyAndReturnOld(m map[string]string, key, val string) string

func SetIfExist

func SetIfExist(from, to map[string]string, key string)

SetIfExist SetIfExist

func SetLabelsDefaultValue

func SetLabelsDefaultValue(key, value string, meta *metav1.ObjectMeta)

SetLabelsDefaultValue SetLabelsDefaultValue

func SetLaunchSignature

func SetLaunchSignature(object metav1.Object, sig int64)

SetLaunchSignature SetLaunchSignature

func SetLazyV3

func SetLazyV3(object metav1.Object, lazyV3 bool)

SetLazyV3 SetLazyV3

func SetMapValidValue

func SetMapValidValue(k, v string, kv1, kv2 map[string]string)

SetMapValidValue set v to kv1 if it's valid, otherwise hash it and copy raw value to kv2

func SetMigratedFromSubrs

func SetMigratedFromSubrs(object metav1.Object, value string)

SetMigratedFromSubrs SetMigratedFromSubrs

func SetNormalAppSelector

func SetNormalAppSelector(selector *metav1.LabelSelector, appName string) error

SetNormalAppSelector use LabelKeyAppName

func SetObjectAppName

func SetObjectAppName(object metav1.Object, app string)

SetObjectAppName set appname for to this object.

func SetObjectAppRoleName

func SetObjectAppRoleName(object metav1.Object, app, role string)

SetObjectAppRoleName set app & role to this object App & Role are used by hippo for 2 purposes: a) group by ops; b) create working dir

func SetObjectAppRoleNameHash

func SetObjectAppRoleNameHash(object metav1.Object, app, role, group string)

func SetObjectGroupHash

func SetObjectGroupHash(object metav1.Object, app, group string)

SetObjectGroupHash group hash is used for group selection

func SetObjectRoleHash

func SetObjectRoleHash(object metav1.Object, app, role string)

SetObjectRoleHash role hash is used for role selection

func SetObjectValidLabel

func SetObjectValidLabel(object metav1.Object, k, v string)

SetObjectValidLabel set label if the value is valid, otherwise write the raw value in the annotation

func SetObjectZoneName

func SetObjectZoneName(object metav1.Object, zone string)

SetObjectZoneName set appname for to this object.

func SetPackageChecksum

func SetPackageChecksum(object metav1.Object, version string)

SetPackageChecksum SetPackageChecksum

func SetPodVersion

func SetPodVersion(object metav1.Object, podVersion string)

SetPodVersion SetPodVersion

func SetPodVersionSelector

func SetPodVersionSelector(selector *metav1.LabelSelector, podVersion string) error

SetPodVersionSelector setPodVersionSelector

func SetPodVersionsSelector

func SetPodVersionsSelector(selector *metav1.LabelSelector, podVersions ...string) error

SetPodVersionsSelector SetPodVersionsSelector

func SetPoolStatus

func SetPoolStatus(rs *RollingSet, status, version string)

func SetQuotaID

func SetQuotaID(object metav1.Object, quotaID string)

SetQuotaID SetQuotaID

func SetReplicaAnnotation

func SetReplicaAnnotation(replica *Replica, key string, value string)

SetReplicaAnnotation set Annotation

func SetReplicaVersionPlanWithGangPlan

func SetReplicaVersionPlanWithGangPlan(replica *Replica, versionPlans *VersionPlanWithGangPlan, version string) error

SetReplicaVersionPlanWithGangPlan set replica VersionPlanWithGangPlan

func SetRequirementID

func SetRequirementID(object metav1.Object, version string)

SetRequirementID SetRequirementID

func SetRoleName

func SetRoleName(object metav1.Object, role string)

SetRoleName set role to this object

func SetRoleSelector

func SetRoleSelector(selector *metav1.LabelSelector, roleName string) error

SetRoleSelector SetRoleSelector

func SetRolesSelector

func SetRolesSelector(selector *metav1.LabelSelector, roleNames ...string) error

SetRolesSelector SetRolesSelector

func SetServiceVersion

func SetServiceVersion(object metav1.Object, v string)

SetServiceVersion SetServiceVersion

func SetSilence

func SetSilence(w *WorkerNode, silence bool) bool

SetSilence get the pod name of worker

func SetSsID

func SetSsID(object metav1.Object, id string)

SetSsID SetSsID

func SetStandby2Active

func SetStandby2Active(w *WorkerNode) bool

SetStandby2Active set

func SetSubrsMetas

func SetSubrsMetas(rs *RollingSet, metas string)

func SetUnassignedReason

func SetUnassignedReason(worker *WorkerNode, reason UnassignedReasonType)

SetUnassignedReason SetUnassignedReason

func SetWorkerAssigned

func SetWorkerAssigned(worker *WorkerNode)

SetWorkerAssigned setter

func SetWorkerBackup

func SetWorkerBackup(worker *WorkerNode)

SetWorkerBackup SetWorkerBackup

func SetWorkerCurrent

func SetWorkerCurrent(worker *WorkerNode)

SetWorkerCurrent SetWorkerCurrent

func SetWorkerEntity

func SetWorkerEntity(worker *WorkerNode, name, uid string)

SetWorkerEntity judge is the worker is allocated

func SetWorkerEntityAlloced

func SetWorkerEntityAlloced(worker *WorkerNode, alloced bool)

SetWorkerEntityAlloced judge is the worker is allocated

func SetWorkerLost

func SetWorkerLost(worker *WorkerNode)

SetWorkerLost setter

func SetWorkerOfflining

func SetWorkerOfflining(worker *WorkerNode)

SetWorkerOfflining setter

func SetWorkerProhibit

func SetWorkerProhibit(worker *WorkerNode, prohibit bool)

SetWorkerProhibit SetWorkerProhibit

func SetWorkerReleased

func SetWorkerReleased(worker *WorkerNode)

SetWorkerReleased setter

func SetWorkerReleasing

func SetWorkerReleasing(worker *WorkerNode)

SetWorkerReleasing setter

func SetWorkerToRelease

func SetWorkerToRelease(worker *WorkerNode)

SetWorkerToRelease setter

func SetWorkerUnAssigned

func SetWorkerUnAssigned(worker *WorkerNode)

SetWorkerUnAssigned setter

func SetZoneSelector

func SetZoneSelector(selector *metav1.LabelSelector, zoneName string) error

SetZoneSelector SetZoneSelector

func SignGangVersionPlan

func SignGangVersionPlan(versionPlans map[string]*VersionPlan, labels map[string]string, name string) (string, string, error)

SignGangVersionPlan sign gang version plan

func SignVersionPlan

func SignVersionPlan(versionPlan *VersionPlan, labels map[string]string, name string) (string, string, error)

SignVersionPlan sign version plan

func SignWorkerRequirementID

func SignWorkerRequirementID(worker *WorkerNode, suffix string) (string, error)

SignWorkerRequirementID SignWorkerRequirementID

func SliceEquals

func SliceEquals(s1, s2 []int64) bool

func SwapAndReleaseBackup

func SwapAndReleaseBackup(current, backup *WorkerNode) error

SwapAndReleaseBackup swap current and backup , release backup

func SwapLabelsAnnos

func SwapLabelsAnnos(meta1, meta2 metav1.Object, prefix []string)

func SyncCold2Warm4Update

func SyncCold2Warm4Update(worker *WorkerNode) bool

SyncCold2Warm4Update get the pod name of worker

func SyncCrdTime

func SyncCrdTime(old *metav1.ObjectMeta, new *metav1.ObjectMeta)

SyncCrdTime sync crd time //concurrent map writes 问题无法解决

func SyncSilence

func SyncSilence(w *WorkerNode, targetWorkerMode WorkerModeType) bool

SyncSilence get the pod name of worker

func SyncWorkerInUpdating

func SyncWorkerInUpdating(worker *WorkerNode)

SyncWorkerInUpdating sync worker InUpdating status

func UnsetStandby2Active

func UnsetStandby2Active(w *WorkerNode) bool

UnsetStandby2Active unset

func UpdateReplicaResource

func UpdateReplicaResource(replica *Replica, target *HippoPodSpec,
	labels map[string]string, resourceVersion string, workerSchedulePlan WorkerSchedulePlan) error

UpdateReplicaResource update replica resource fields

func UseUnifiedStorageVolume

func UseUnifiedStorageVolume(meta *metav1.ObjectMeta) bool

UseUnifiedStorageVolume UseUnifiedStorageVolume

func WorkerAvailableScore

func WorkerAvailableScore(worker *WorkerNode) int32

WorkerAvailableScore compute the score of Worker available

func WorkerCompleteScore

func WorkerCompleteScore(worker *WorkerNode) int32

WorkerCompleteScore compute the score of Worker complete

func WorkerModeScore

func WorkerModeScore(worker *WorkerNode) int32

WorkerModeScore compute the score of Worker mode

func WorkerProcessScore

func WorkerProcessScore(worker *WorkerNode) int32

WorkerProcessScore compute the score of Worker process

func WorkerReadyScore

func WorkerReadyScore(worker *WorkerNode) int32

WorkerReadyScore compute the score of Worker Ready

func WorkerReclaimScore

func WorkerReclaimScore(worker *WorkerNode) int32

WorkerReclaimScore compute the score of Worker reclaim

func WorkerReleaseScore

func WorkerReleaseScore(worker *WorkerNode) int32

WorkerReleaseScore compute the score of Worker Release

func WorkerResourcePoolScore

func WorkerResourcePoolScore(worker *WorkerNode) int32

func WorkerResourceScore

func WorkerResourceScore(worker *WorkerNode) int32

WorkerResourceScore compute the score of Worker resource match

func WorkerServiceReadyScore

func WorkerServiceReadyScore(worker *WorkerNode) int32

WorkerServiceReadyScore WorkerServiceReadyScore

Types

type ActivePlan

type ActivePlan struct {
	ScaleSchedulePlan *ScaleSchedulePlan `json:"scaleSchedulePlan,omitempty"`
	ScaleConfig       *ScaleConfig       `json:"scaleConfig,omitempty"`
}

ActivePlan ActivePlan

func (*ActivePlan) DeepCopy

func (in *ActivePlan) DeepCopy() *ActivePlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ActivePlan.

func (*ActivePlan) DeepCopyInto

func (in *ActivePlan) DeepCopyInto(out *ActivePlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type AllocStatus

type AllocStatus string

AllocStatus define a alloc status type

const (
	WorkerUnAssigned AllocStatus = "UNASSIGNED"
	WorkerAssigned   AllocStatus = "ASSIGNED"
	WorkerLost       AllocStatus = "LOST"
	WorkerOfflining  AllocStatus = "OFFLINING"
	WorkerReleasing  AllocStatus = "RELEASING"
	WorkerReleased   AllocStatus = "RELEASED"
)

These are the valid statuses of worker node.

type AllocatorSyncedStatus

type AllocatorSyncedStatus struct {
	// Ip  address. from pod ip.
	IP string `json:"ip,omitempty"`

	// HostIP  address. from host.
	HostIP string `json:"hostIP,omitempty"`

	// ResourceMatch describes if the running container match the requirement in plan, eg :cpu mem.
	ResourceMatch bool `json:"resourceMatch"`
	// ProcessMatch describes if the running process match the plan
	ProcessMatch bool `json:"processMatch"`

	// LastResourceNotMatchtime describe the last time resource not match
	// +optional
	LastResourceNotMatchtime int64 `json:"lastResourceNotMatchtime,omitempty"`
	// LastProcessNotMatchtime describe the last time process not match
	// +optional
	LastProcessNotMatchtime int64 `json:"lastProcessNotMatchtime,omitempty"`

	ResVersion string `json:"resVersion"`
	// Version means the signature of VersionPlan.
	Version        string `json:"version"`
	UserDefVersion string `json:"userDefVersion,omitempty"`

	// ProcessScore filled by allocators  .
	ProcessScore int32 `json:"processScore"`

	// The phase of a Worker is a simple, high-level summary of where the Worker is in its lifecycle.
	Phase WorkerPhase `json:"phase"`

	PackageStatus string `json:"packageStatus"`

	// Is replica should be reclaimed .
	// +optional
	Reclaim         bool `json:"reclaim"`
	InternalReclaim bool `json:"internalReclaim"`

	// ready status provide by allocator
	ProcessReady            bool           `json:"processReady,omitempty"`
	NamingRegisteredReady   bool           `json:"namingRegisteredReady,omitempty"`
	EntityName              string         `json:"entityName"`
	EntityAlloced           bool           `json:"entityAlloced"`
	ResourcePool            string         `json:"resourcePool"`
	WorkerMode              WorkerModeType `json:"workerMode,omitempty"`
	PodNotStarted           bool           `json:"-"`
	NotScheduleSeconds      int            `json:"-"`
	LastProcessNotReadytime int64          `json:"lastProcessNotReadytime,omitempty"`

	UnassignedReason         UnassignedReasonType `json:"unassignedReason,omitempty"`
	UnassignedMessage        string               `json:"unassignedMessage,omitempty"`
	HistoryUnassignedMessage string               `json:"historyUnassignedMessage,omitempty"`
	DeletionCost             int64                `json:"deletionCost,omitempty"`
	StandbyHours             string               `json:"standbyHours,omitempty"`
	EntityUid                string               `json:"entityUid"`
}

AllocatorSyncedStatus is worker status synced by allocator

func (*AllocatorSyncedStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AllocatorSyncedStatus.

func (*AllocatorSyncedStatus) DeepCopyInto

func (in *AllocatorSyncedStatus) DeepCopyInto(out *AllocatorSyncedStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*AllocatorSyncedStatus) Descriptor

func (*AllocatorSyncedStatus) Descriptor() ([]byte, []int)

func (*AllocatorSyncedStatus) Marshal

func (m *AllocatorSyncedStatus) Marshal() (dAtA []byte, err error)

func (*AllocatorSyncedStatus) MarshalTo

func (m *AllocatorSyncedStatus) MarshalTo(dAtA []byte) (int, error)

func (*AllocatorSyncedStatus) MarshalToSizedBuffer

func (m *AllocatorSyncedStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AllocatorSyncedStatus) ProtoMessage

func (*AllocatorSyncedStatus) ProtoMessage()

func (*AllocatorSyncedStatus) Reset

func (m *AllocatorSyncedStatus) Reset()

func (*AllocatorSyncedStatus) Size

func (m *AllocatorSyncedStatus) Size() (n int)

func (*AllocatorSyncedStatus) String

func (this *AllocatorSyncedStatus) String() string

func (*AllocatorSyncedStatus) Unmarshal

func (m *AllocatorSyncedStatus) Unmarshal(dAtA []byte) error

func (*AllocatorSyncedStatus) XXX_DiscardUnknown

func (m *AllocatorSyncedStatus) XXX_DiscardUnknown()

func (*AllocatorSyncedStatus) XXX_Marshal

func (m *AllocatorSyncedStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AllocatorSyncedStatus) XXX_Merge

func (m *AllocatorSyncedStatus) XXX_Merge(src proto.Message)

func (*AllocatorSyncedStatus) XXX_Size

func (m *AllocatorSyncedStatus) XXX_Size() int

func (*AllocatorSyncedStatus) XXX_Unmarshal

func (m *AllocatorSyncedStatus) XXX_Unmarshal(b []byte) error

type AppNodeStatus

type AppNodeStatus struct {
	AppId         string `json:"appId"`
	StartedAt     uint64 `json:"startedAt"`
	PlanStatus    int32  `json:"planStatus"`
	ServiceStatus int32  `json:"serviceStatus"`
	NeedBackup    bool   `json:"needBackup"`
}

AppsStatus means a scene plan status on a workerNode

func (*AppNodeStatus) DeepCopy

func (in *AppNodeStatus) DeepCopy() *AppNodeStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppNodeStatus.

func (*AppNodeStatus) DeepCopyInto

func (in *AppNodeStatus) DeepCopyInto(out *AppNodeStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BackupOfPod

type BackupOfPod struct {
	Name string `json:"name,omitempty"`
	Uid  string `json:"uid,omitempty"`
}

BackupOfPod point to logic current pod

func (*BackupOfPod) DeepCopy

func (in *BackupOfPod) DeepCopy() *BackupOfPod

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupOfPod.

func (*BackupOfPod) DeepCopyInto

func (in *BackupOfPod) DeepCopyInto(out *BackupOfPod)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BackupOfPod) Descriptor

func (*BackupOfPod) Descriptor() ([]byte, []int)

func (*BackupOfPod) Marshal

func (m *BackupOfPod) Marshal() (dAtA []byte, err error)

func (*BackupOfPod) MarshalTo

func (m *BackupOfPod) MarshalTo(dAtA []byte) (int, error)

func (*BackupOfPod) MarshalToSizedBuffer

func (m *BackupOfPod) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*BackupOfPod) ProtoMessage

func (*BackupOfPod) ProtoMessage()

func (*BackupOfPod) Reset

func (m *BackupOfPod) Reset()

func (*BackupOfPod) Size

func (m *BackupOfPod) Size() (n int)

func (*BackupOfPod) String

func (this *BackupOfPod) String() string

func (*BackupOfPod) Unmarshal

func (m *BackupOfPod) Unmarshal(dAtA []byte) error

func (*BackupOfPod) XXX_DiscardUnknown

func (m *BackupOfPod) XXX_DiscardUnknown()

func (*BackupOfPod) XXX_Marshal

func (m *BackupOfPod) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BackupOfPod) XXX_Merge

func (m *BackupOfPod) XXX_Merge(src proto.Message)

func (*BackupOfPod) XXX_Size

func (m *BackupOfPod) XXX_Size() int

func (*BackupOfPod) XXX_Unmarshal

func (m *BackupOfPod) XXX_Unmarshal(b []byte) error

type BadReasonType

type BadReasonType int

BadReasonType BadReasonType

const (
	BadReasonNone            BadReasonType = 0
	BadReasonLost            BadReasonType = 1
	BadReasonDead            BadReasonType = 2
	BadReasonNotMatch        BadReasonType = 3
	BadReasonProcessNotMatch BadReasonType = 4
	BadReasonNotReady        BadReasonType = 5
	BadReasonReclaim         BadReasonType = 6
	BadReasonRelease         BadReasonType = 7
	BadReasonNotSchedule     BadReasonType = 8
	BadReasonProcessNotReady BadReasonType = 9
	BadReasonServiceReclaim  BadReasonType = 10
)

BadReasons

func GetWorkerBadState

func GetWorkerBadState(worker *WorkerNode, targetVersion string) BadReasonType

GetWorkerBadState means is worker is in wrong status

func IsWorkerBroken

func IsWorkerBroken(worker *WorkerNode, targetVersion string) BadReasonType

IsWorkerBroken means is worker is in wrong status not by unexpected

type BroadcastPlan

type BroadcastPlan struct {
	WorkerSchedulePlan `json:",inline"`
	//CustomInfo suez服务信息
	CustomInfo string `json:"customInfo,omitempty"`
	//json string compressed of CustomInfo
	CompressedCustomInfo string `json:"compressedCustomInfo,omitempty"`
	UserDefVersion       string `json:"userDefVersion,omitempty"`
	// Online means is need to publish
	Online *bool `json:"online,omitempty"`
	// UpdatingGracefully means is need to unpublish before update
	UpdatingGracefully *bool `json:"updatingGracefully,omitempty"`
	//Preload advanced lv7,suez worker 是否做数据预加载
	Preload             bool   `json:"preload,omitempty"`
	IsDaemonSet         bool   `json:"isDaemonSet,omitempty"`
	CPU                 *int32 `json:"-"` // 内部变量,用于计算cpu可用度。不对外展示
	UpdatePlanTimestamp int64  `json:"updatePlanTimestamp,omitempty"`
	RowComplete         *bool  `json:"rowComplete,omitempty"`
}

BroadcastPlan BroadcastPlan

func (*BroadcastPlan) DeepCopy

func (in *BroadcastPlan) DeepCopy() *BroadcastPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BroadcastPlan.

func (*BroadcastPlan) DeepCopyInto

func (in *BroadcastPlan) DeepCopyInto(out *BroadcastPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BroadcastPlan) Descriptor

func (*BroadcastPlan) Descriptor() ([]byte, []int)

func (*BroadcastPlan) Marshal

func (m *BroadcastPlan) Marshal() (dAtA []byte, err error)

func (*BroadcastPlan) MarshalTo

func (m *BroadcastPlan) MarshalTo(dAtA []byte) (int, error)

func (*BroadcastPlan) MarshalToSizedBuffer

func (m *BroadcastPlan) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*BroadcastPlan) ProtoMessage

func (*BroadcastPlan) ProtoMessage()

func (*BroadcastPlan) Reset

func (m *BroadcastPlan) Reset()

func (*BroadcastPlan) Size

func (m *BroadcastPlan) Size() (n int)

func (*BroadcastPlan) String

func (this *BroadcastPlan) String() string

func (*BroadcastPlan) Unmarshal

func (m *BroadcastPlan) Unmarshal(dAtA []byte) error

func (*BroadcastPlan) XXX_DiscardUnknown

func (m *BroadcastPlan) XXX_DiscardUnknown()

func (*BroadcastPlan) XXX_Marshal

func (m *BroadcastPlan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BroadcastPlan) XXX_Merge

func (m *BroadcastPlan) XXX_Merge(src proto.Message)

func (*BroadcastPlan) XXX_Size

func (m *BroadcastPlan) XXX_Size() int

func (*BroadcastPlan) XXX_Unmarshal

func (m *BroadcastPlan) XXX_Unmarshal(b []byte) error

type BrokenRecoverQuotaConfig

type BrokenRecoverQuotaConfig struct {
	MaxFailedCount *int32 `json:"maxFailedCount"`
	TimeWindow     *int32 `json:"timeWindow"` // sec
}

BrokenRecoverQuotaConfig is the spec for a SchedulePlan resource

func (*BrokenRecoverQuotaConfig) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BrokenRecoverQuotaConfig.

func (*BrokenRecoverQuotaConfig) DeepCopyInto

func (in *BrokenRecoverQuotaConfig) DeepCopyInto(out *BrokenRecoverQuotaConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BrokenRecoverQuotaConfig) Descriptor

func (*BrokenRecoverQuotaConfig) Descriptor() ([]byte, []int)

func (*BrokenRecoverQuotaConfig) Marshal

func (m *BrokenRecoverQuotaConfig) Marshal() (dAtA []byte, err error)

func (*BrokenRecoverQuotaConfig) MarshalTo

func (m *BrokenRecoverQuotaConfig) MarshalTo(dAtA []byte) (int, error)

func (*BrokenRecoverQuotaConfig) MarshalToSizedBuffer

func (m *BrokenRecoverQuotaConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*BrokenRecoverQuotaConfig) ProtoMessage

func (*BrokenRecoverQuotaConfig) ProtoMessage()

func (*BrokenRecoverQuotaConfig) Reset

func (m *BrokenRecoverQuotaConfig) Reset()

func (*BrokenRecoverQuotaConfig) Size

func (m *BrokenRecoverQuotaConfig) Size() (n int)

func (*BrokenRecoverQuotaConfig) String

func (this *BrokenRecoverQuotaConfig) String() string

func (*BrokenRecoverQuotaConfig) Unmarshal

func (m *BrokenRecoverQuotaConfig) Unmarshal(dAtA []byte) error

func (*BrokenRecoverQuotaConfig) XXX_DiscardUnknown

func (m *BrokenRecoverQuotaConfig) XXX_DiscardUnknown()

func (*BrokenRecoverQuotaConfig) XXX_Marshal

func (m *BrokenRecoverQuotaConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BrokenRecoverQuotaConfig) XXX_Merge

func (m *BrokenRecoverQuotaConfig) XXX_Merge(src proto.Message)

func (*BrokenRecoverQuotaConfig) XXX_Size

func (m *BrokenRecoverQuotaConfig) XXX_Size() int

func (*BrokenRecoverQuotaConfig) XXX_Unmarshal

func (m *BrokenRecoverQuotaConfig) XXX_Unmarshal(b []byte) error

type BufferDistribute

type BufferDistribute struct {
	Cold int32 `json:"cold"`
	Warm int32 `json:"warm"`
	Hot  int32 `json:"hot"`
}

BufferDistribute Buffer配置

func (*BufferDistribute) DeepCopy

func (in *BufferDistribute) DeepCopy() *BufferDistribute

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BufferDistribute.

func (*BufferDistribute) DeepCopyInto

func (in *BufferDistribute) DeepCopyInto(out *BufferDistribute)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BufferDistributeRatio

type BufferDistributeRatio BufferDistribute

BufferDistributeRatio buffer分池比例配置

func (*BufferDistributeRatio) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BufferDistributeRatio.

func (*BufferDistributeRatio) DeepCopyInto

func (in *BufferDistributeRatio) DeepCopyInto(out *BufferDistributeRatio)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BufferPlan

type BufferPlan struct {
	Distribute *BufferDistribute `json:"distribute"`
}

BufferPlan BufferPlan

func (*BufferPlan) DeepCopy

func (in *BufferPlan) DeepCopy() *BufferPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BufferPlan.

func (*BufferPlan) DeepCopyInto

func (in *BufferPlan) DeepCopyInto(out *BufferPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BufferSwapRecord

type BufferSwapRecord struct {
	Version  string `json:"version"`
	SwapAt   int64  `json:"swapAt"`
	Previous string `json:"previous"`
}

func (*BufferSwapRecord) DeepCopy

func (in *BufferSwapRecord) DeepCopy() *BufferSwapRecord

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BufferSwapRecord.

func (*BufferSwapRecord) DeepCopyInto

func (in *BufferSwapRecord) DeepCopyInto(out *BufferSwapRecord)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Capacity

type Capacity struct {
	// 总资源容量(Active+Buffer)
	Total *int32 `json:"total"`
	// Buffer资源相关
	BufferPlan BufferPlan `json:"bufferPlan"`
	// Active资源(弹性)相关
	ActivePlan     ActivePlan `json:"activePlan"`
	ActualReplicas int        `json:"actualReplicas"`
}

Capacity ...

func (*Capacity) DeepCopy

func (in *Capacity) DeepCopy() *Capacity

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Capacity.

func (*Capacity) DeepCopyInto

func (in *Capacity) DeepCopyInto(out *Capacity)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CarbonAppPlan

type CarbonAppPlan struct {
	Groups map[string]*typespec.GroupPlan `json:"groups"`
}

CarbonAppPlan appPlan for CarbonJob

func (*CarbonAppPlan) DeepCopy

func (in *CarbonAppPlan) DeepCopy() *CarbonAppPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CarbonAppPlan.

func (*CarbonAppPlan) DeepCopyInto

func (in *CarbonAppPlan) DeepCopyInto(out *CarbonAppPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*CarbonAppPlan) MarshalJSON

func (cap *CarbonAppPlan) MarshalJSON() ([]byte, error)

MarshalJSON MarshalJSON

type CarbonJob

type CarbonJob struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   CarbonJobSpec   `json:"spec"`
	Status CarbonJobStatus `json:"status"`
}

CarbonJob CabronJob

func (*CarbonJob) DeepCopy

func (in *CarbonJob) DeepCopy() *CarbonJob

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CarbonJob.

func (*CarbonJob) DeepCopyInto

func (in *CarbonJob) DeepCopyInto(out *CarbonJob)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*CarbonJob) DeepCopyObject

func (in *CarbonJob) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*CarbonJob) GetTaskSize

func (cb *CarbonJob) GetTaskSize() int

type CarbonJobList

type CarbonJobList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []CarbonJob `json:"items"`
}

CarbonJobList CarbonJobList

func (*CarbonJobList) DeepCopy

func (in *CarbonJobList) DeepCopy() *CarbonJobList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CarbonJobList.

func (*CarbonJobList) DeepCopyInto

func (in *CarbonJobList) DeepCopyInto(out *CarbonJobList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*CarbonJobList) DeepCopyObject

func (in *CarbonJobList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type CarbonJobPlan

type CarbonJobPlan struct {
	WorkerNodes map[string]WorkerNodeTemplate `json:"workerNodes,omitempty"`
}

func (*CarbonJobPlan) DeepCopy

func (in *CarbonJobPlan) DeepCopy() *CarbonJobPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CarbonJobPlan.

func (*CarbonJobPlan) DeepCopyInto

func (in *CarbonJobPlan) DeepCopyInto(out *CarbonJobPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CarbonJobSpec

type CarbonJobSpec struct {
	AppName  string         `json:"appName,omitempty"`
	Checksum string         `json:"checksum,omitempty"`
	AppPlan  *CarbonAppPlan `json:"appPlan,omitempty"`
	JobPlan  *CarbonJobPlan `json:"jobPlan,omitempty"`
}

CarbonJobSpec spec for CarbonJobResource

func (*CarbonJobSpec) DeepCopy

func (in *CarbonJobSpec) DeepCopy() *CarbonJobSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CarbonJobSpec.

func (*CarbonJobSpec) DeepCopyInto

func (in *CarbonJobSpec) DeepCopyInto(out *CarbonJobSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CarbonJobStatus

type CarbonJobStatus struct {
	SuccessCount int `json:"successCount"`
	DeadCount    int `json:"deadCount"`
	TotalCount   int `json:"totalCount"`
	TargetCount  int `json:"targetCount"`
}

CarbonJobStatus status for carbon job

func (*CarbonJobStatus) DeepCopy

func (in *CarbonJobStatus) DeepCopy() *CarbonJobStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CarbonJobStatus.

func (*CarbonJobStatus) DeepCopyInto

func (in *CarbonJobStatus) DeepCopyInto(out *CarbonJobStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ContainerConfig

type ContainerConfig struct {
	Ulimits           []Ulimit `json:"ulimits,omitempty"`
	RestartCountLimit int      `json:"restartCountLimit,omitempty"`
	StopGracePeriod   int      `json:"stopGracePeriod,omitempty"`

	CPUBvtWarpNs        string `json:"CPU_BVT_WARP_NS,omitempty"`
	CPUllcCache         string `json:"CPU_LLC_CACHE,omitempty"`
	NetPriority         string `json:"NET_PRIORITY,omitempty"`
	NoMemcgReclaim      string `json:"NO_MEMCG_RECLAIM,omitempty"`
	MemWmarkRatio       string `json:"MEM_WMARK_RATIO,omitempty"`
	MemForceEmpty       string `json:"MEM_FORCE_EMPTY,omitempty"`
	MemExtraBytes       string `json:"MEM_EXTRA_BYTES,omitempty"`
	MemExtraRatio       string `json:"MEM_EXTRA_RATIO,omitempty"`
	PredictDelaySeconds string `json:"PREDICT_DELAY_SECONDS,omitempty"`
}

ContainerConfig is config of container

func GetContainersConfigs

func GetContainersConfigs(name string, worker *WorkerNode) *ContainerConfig

func (*ContainerConfig) DeepCopy

func (in *ContainerConfig) DeepCopy() *ContainerConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContainerConfig.

func (*ContainerConfig) DeepCopyInto

func (in *ContainerConfig) DeepCopyInto(out *ContainerConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ContainerConfig) Descriptor

func (*ContainerConfig) Descriptor() ([]byte, []int)

func (*ContainerConfig) Marshal

func (m *ContainerConfig) Marshal() (dAtA []byte, err error)

func (*ContainerConfig) MarshalTo

func (m *ContainerConfig) MarshalTo(dAtA []byte) (int, error)

func (*ContainerConfig) MarshalToSizedBuffer

func (m *ContainerConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContainerConfig) ProtoMessage

func (*ContainerConfig) ProtoMessage()

func (*ContainerConfig) Reset

func (m *ContainerConfig) Reset()

func (*ContainerConfig) Size

func (m *ContainerConfig) Size() (n int)

func (*ContainerConfig) String

func (this *ContainerConfig) String() string

func (*ContainerConfig) Unmarshal

func (m *ContainerConfig) Unmarshal(dAtA []byte) error

func (*ContainerConfig) XXX_DiscardUnknown

func (m *ContainerConfig) XXX_DiscardUnknown()

func (*ContainerConfig) XXX_Marshal

func (m *ContainerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContainerConfig) XXX_Merge

func (m *ContainerConfig) XXX_Merge(src proto.Message)

func (*ContainerConfig) XXX_Size

func (m *ContainerConfig) XXX_Size() int

func (*ContainerConfig) XXX_Unmarshal

func (m *ContainerConfig) XXX_Unmarshal(b []byte) error

type ContainerHippoExterned

type ContainerHippoExterned struct {
	Labels         map[string]string `json:"Labels,omitempty"`
	PreDeployImage string            `json:"PreDeployImage,omitempty"`
	HostConfig     json.RawMessage   `json:"HostConfig,omitempty"`
	Devices        []Device          `json:"devices,omitempty"`
	Configs        *ContainerConfig  `json:"configs,omitempty"`
	Alias          string            `json:"alias,omitempty"`
}

ContainerHippoExterned defines the hippo container

func (*ContainerHippoExterned) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContainerHippoExterned.

func (*ContainerHippoExterned) DeepCopyInto

func (in *ContainerHippoExterned) DeepCopyInto(out *ContainerHippoExterned)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ContainerHippoExterned) Descriptor

func (*ContainerHippoExterned) Descriptor() ([]byte, []int)

func (*ContainerHippoExterned) Marshal

func (m *ContainerHippoExterned) Marshal() (dAtA []byte, err error)

func (*ContainerHippoExterned) MarshalTo

func (m *ContainerHippoExterned) MarshalTo(dAtA []byte) (int, error)

func (*ContainerHippoExterned) MarshalToSizedBuffer

func (m *ContainerHippoExterned) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContainerHippoExterned) ProtoMessage

func (*ContainerHippoExterned) ProtoMessage()

func (*ContainerHippoExterned) Reset

func (m *ContainerHippoExterned) Reset()

func (*ContainerHippoExterned) Size

func (m *ContainerHippoExterned) Size() (n int)

func (*ContainerHippoExterned) String

func (this *ContainerHippoExterned) String() string

func (*ContainerHippoExterned) Unmarshal

func (m *ContainerHippoExterned) Unmarshal(dAtA []byte) error

func (*ContainerHippoExterned) XXX_DiscardUnknown

func (m *ContainerHippoExterned) XXX_DiscardUnknown()

func (*ContainerHippoExterned) XXX_Marshal

func (m *ContainerHippoExterned) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContainerHippoExterned) XXX_Merge

func (m *ContainerHippoExterned) XXX_Merge(src proto.Message)

func (*ContainerHippoExterned) XXX_Size

func (m *ContainerHippoExterned) XXX_Size() int

func (*ContainerHippoExterned) XXX_Unmarshal

func (m *ContainerHippoExterned) XXX_Unmarshal(b []byte) error

type ContainerHippoExternedWithName

type ContainerHippoExternedWithName struct {
	Name                   string `json:"name,omitempty"`
	InstanceID             string `json:"instanceId,omitempty"`
	ContainerHippoExterned `json:",inline"`
}

ContainerHippoExternedWithName used for commit pod to hippo

func (*ContainerHippoExternedWithName) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContainerHippoExternedWithName.

func (*ContainerHippoExternedWithName) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ContainerInstanceField

type ContainerInstanceField struct {
	Name           string                      `json:"name"`
	Alias          string                      `json:"alias,omitempty"`
	Image          string                      `json:"image,omitempty"`
	Command        []string                    `json:"command,omitempty"`
	Args           []string                    `json:"args,omitempty"`
	WorkingDir     string                      `json:"workingDir,omitempty"`
	Ports          []corev1.ContainerPort      `json:"ports,omitempty"`
	EnvFrom        []corev1.EnvFromSource      `json:"envFrom,omitempty"`
	Env            []corev1.EnvVar             `json:"env,omitempty"`
	VolumeMounts   []corev1.VolumeMount        `json:"volumeMounts,omitempty"`
	VolumeDevices  []corev1.VolumeDevice       `json:"volumeDevices,omitempty"`
	Lifecycle      *LifecycleInstanceField     `json:"lifecycle,omitempty"`
	Resources      corev1.ResourceRequirements `json:"resources,omitempty"`
	Labels         map[string]string           `json:"Labels,omitempty"`
	PreDeployImage string                      `json:"PreDeployImage,omitempty"`
	HostConfig     json.RawMessage             `json:"HostConfig,omitempty"`
	Devices        []Device                    `json:"device,omitempty"`
	Configs        *ContainerConfig            `json:"configs,omitempty"`
}

ContainerInstanceField means container instance resource

func (*ContainerInstanceField) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContainerInstanceField.

func (*ContainerInstanceField) DeepCopyInto

func (in *ContainerInstanceField) DeepCopyInto(out *ContainerInstanceField)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ContainerModelType

type ContainerModelType string

ContainerModelType defines container mode

const (
	ContainerDocker        ContainerModelType = "DOCKER"
	ContainerCgroupProcess ContainerModelType = "CGROUPPROCESS"
	ContainerDockerVM      ContainerModelType = "DOCKERVM"
	ContainerKVM           ContainerModelType = "KVM"
)

containers modes enum

type ContainerResource

type ContainerResource struct {
	Resources corev1.ResourceRequirements `json:"resources,omitempty"`
}

ContainerResource means container resource require

func (*ContainerResource) DeepCopy

func (in *ContainerResource) DeepCopy() *ContainerResource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContainerResource.

func (*ContainerResource) DeepCopyInto

func (in *ContainerResource) DeepCopyInto(out *ContainerResource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ContainerStatusHippoExterned

type ContainerStatusHippoExterned struct {
	Name       string `json:"name,omitempty"`
	InstanceID string `json:"instanceId,omitempty"`
}

ContainerStatusHippoExterned defines the hippo container

func (*ContainerStatusHippoExterned) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContainerStatusHippoExterned.

func (*ContainerStatusHippoExterned) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CopyTarget

type CopyTarget map[string][]string

CopyTarget key is prefix (e.g. app.c2.io), val is sourceFullKey (e.g. app.hippo.io/pod-version), result is app.c2.io/pod-version

func (CopyTarget) DeepCopy

func (in CopyTarget) DeepCopy() CopyTarget

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CopyTarget.

func (CopyTarget) DeepCopyInto

func (in CopyTarget) DeepCopyInto(out *CopyTarget)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CpusetModeType

type CpusetModeType string

CpusetModeType defines cpu mode

const (
	CpusetReserved  CpusetModeType = "RESERVED"
	CpusetExclusive CpusetModeType = "EXCLUSIVE"
	CpusetShare     CpusetModeType = "SHARE"
	CpusetNone      CpusetModeType = "NONE"
)

cpu modes enum

type Detail

type Detail struct {
	Scenes []SceneNode `json:"scenes"`
}

func (*Detail) DeepCopy

func (in *Detail) DeepCopy() *Detail

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Detail.

func (*Detail) DeepCopyInto

func (in *Detail) DeepCopyInto(out *Detail)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Device

type Device struct {
	PathOnHost        string
	PathInContainer   string
	CgroupPermissions string
}

Device mount host device to container

func (*Device) DeepCopy

func (in *Device) DeepCopy() *Device

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Device.

func (*Device) DeepCopyInto

func (in *Device) DeepCopyInto(out *Device)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Device) Descriptor

func (*Device) Descriptor() ([]byte, []int)

func (*Device) Marshal

func (m *Device) Marshal() (dAtA []byte, err error)

func (*Device) MarshalTo

func (m *Device) MarshalTo(dAtA []byte) (int, error)

func (*Device) MarshalToSizedBuffer

func (m *Device) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Device) ProtoMessage

func (*Device) ProtoMessage()

func (*Device) Reset

func (m *Device) Reset()

func (*Device) Size

func (m *Device) Size() (n int)

func (*Device) String

func (this *Device) String() string

func (*Device) Unmarshal

func (m *Device) Unmarshal(dAtA []byte) error

func (*Device) XXX_DiscardUnknown

func (m *Device) XXX_DiscardUnknown()

func (*Device) XXX_Marshal

func (m *Device) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Device) XXX_Merge

func (m *Device) XXX_Merge(src proto.Message)

func (*Device) XXX_Size

func (m *Device) XXX_Size() int

func (*Device) XXX_Unmarshal

func (m *Device) XXX_Unmarshal(b []byte) error

type Extra

type Extra struct {
	Package string `json:"package"`
}

func (*Extra) DeepCopy

func (in *Extra) DeepCopy() *Extra

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Extra.

func (*Extra) DeepCopyInto

func (in *Extra) DeepCopyInto(out *Extra)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GangInfo

type GangInfo struct {
	Name string `json:"name"`
	IP   string `json:"ip"`
}

GangInfo GangInfo

func (*GangInfo) DeepCopy

func (in *GangInfo) DeepCopy() *GangInfo

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GangInfo.

func (*GangInfo) DeepCopyInto

func (in *GangInfo) DeepCopyInto(out *GangInfo)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GeneralTemplate

type GeneralTemplate struct {
	metav1.TypeMeta `json:",inline"`
	// Standard object's metadata.
	// More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`
}

GeneralTemplate describes a general template

func GetGeneralTemplate

func GetGeneralTemplate(version VersionPlan) (*GeneralTemplate, error)

GetGeneralTemplate get general template from raw template

func (*GeneralTemplate) DeepCopy

func (in *GeneralTemplate) DeepCopy() *GeneralTemplate

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GeneralTemplate.

func (*GeneralTemplate) DeepCopyInto

func (in *GeneralTemplate) DeepCopyInto(out *GeneralTemplate)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GrayPublisher

type GrayPublisher struct {
	// Selector is a label query over pods that should match the replica count.
	// Label keys and values that must match in order to be controlled by this replica set.
	// It must match the pod template's labels.
	// More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors
	Selector *metav1.LabelSelector `json:"selector"`

	TrafficRatio int32 `json:"trafficRatio"`
}

GrayPublisher means publish gray traffic

func (*GrayPublisher) DeepCopy

func (in *GrayPublisher) DeepCopy() *GrayPublisher

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GrayPublisher.

func (*GrayPublisher) DeepCopyInto

func (in *GrayPublisher) DeepCopyInto(out *GrayPublisher)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GroupVersionStatusMap

type GroupVersionStatusMap map[string]*rollalgorithm.VersionStatus

GroupVersionStatusMap ...

func (GroupVersionStatusMap) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GroupVersionStatusMap.

func (GroupVersionStatusMap) DeepCopyInto

func (in GroupVersionStatusMap) DeepCopyInto(out *GroupVersionStatusMap)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type HealthCheckerConfig

type HealthCheckerConfig struct {

	// Type of worker node condition.
	Type HealthConditionType `json:"type"`

	// lv7 HealthChecker 规则参数
	// +optional
	Lv7Config *Lv7HealthCheckerConfig `json:"lv7Config"`
}

HealthCheckerConfig 健康检查配置

func (*HealthCheckerConfig) DeepCopy

func (in *HealthCheckerConfig) DeepCopy() *HealthCheckerConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HealthCheckerConfig.

func (*HealthCheckerConfig) DeepCopyInto

func (in *HealthCheckerConfig) DeepCopyInto(out *HealthCheckerConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type HealthCondition

type HealthCondition struct {
	// Type of worker node condition.
	Type HealthConditionType `json:"type"`
	// Status of the condition.
	Status HealthStatus `json:"status"`
	// The last time the condition transitioned from one status to another.
	// +optional
	LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"`
	// The reason for the condition's last transition.
	// +optional
	Reason string `json:"reason,omitempty"`
	// A human readable message indicating details about the transition.
	// +optional
	Message string `json:"message,omitempty"`

	//时间戳,单位秒
	LastLostTime int64 `json:"lastLostTime,omitempty"`

	LostCount int32 `json:"lostCount,omitempty"`

	//Metas advanced lv7记录的节点返回信息
	Metas   map[string]string `json:"metas,omitempty" until:"1.0.0"`
	Checked bool              `json:"checked,omitempty" until:"1.0.0"`
	//json string compressed of Metas
	CompressedMetas string `json:"compressedMetas,omitempty" until:"1.0.0"`

	//Version workernode版本号
	// +optional
	Version string `json:"version,omitempty"`

	//WorkerStatus advanced lv7判断签名是否匹配
	WorkerStatus WorkerType `json:"workerStatus,omitempty"`
}

HealthCondition describes the health state of a worker at a certain point.

func (*HealthCondition) DeepCopy

func (in *HealthCondition) DeepCopy() *HealthCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HealthCondition.

func (*HealthCondition) DeepCopyInto

func (in *HealthCondition) DeepCopyInto(out *HealthCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*HealthCondition) Descriptor

func (*HealthCondition) Descriptor() ([]byte, []int)

func (*HealthCondition) Marshal

func (m *HealthCondition) Marshal() (dAtA []byte, err error)

func (*HealthCondition) MarshalTo

func (m *HealthCondition) MarshalTo(dAtA []byte) (int, error)

func (*HealthCondition) MarshalToSizedBuffer

func (m *HealthCondition) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HealthCondition) ProtoMessage

func (*HealthCondition) ProtoMessage()

func (*HealthCondition) Reset

func (m *HealthCondition) Reset()

func (*HealthCondition) Size

func (m *HealthCondition) Size() (n int)

func (*HealthCondition) String

func (c *HealthCondition) String() string

func (*HealthCondition) Unmarshal

func (m *HealthCondition) Unmarshal(dAtA []byte) error

func (*HealthCondition) XXX_DiscardUnknown

func (m *HealthCondition) XXX_DiscardUnknown()

func (*HealthCondition) XXX_Marshal

func (m *HealthCondition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HealthCondition) XXX_Merge

func (m *HealthCondition) XXX_Merge(src proto.Message)

func (*HealthCondition) XXX_Size

func (m *HealthCondition) XXX_Size() int

func (*HealthCondition) XXX_Unmarshal

func (m *HealthCondition) XXX_Unmarshal(b []byte) error

type HealthConditionType

type HealthConditionType string

HealthConditionType define a health condition status type

const (
	DefaultHealth     HealthConditionType = "DefaultHealth"
	Lv7Health         HealthConditionType = "Lv7Health"
	AdvancedLv7Health HealthConditionType = "AdvanceLv7Health"
)

These are valid conditions of a health.

type HealthStatus

type HealthStatus string

HealthStatus define a health status type

const (
	HealthUnKnown HealthStatus = "HT_UNKNOWN"
	HealthLost    HealthStatus = "HT_LOST"
	HealthAlive   HealthStatus = "HT_ALIVE"
	HealthDead    HealthStatus = "HT_DEAD"
)

These are the valid statuses of worker health.

func GetHealthStatusByPhase

func GetHealthStatusByPhase(worker *WorkerNode) HealthStatus

GetHealthStatusByPhase GetHealthStatusByPhase

func SetWorkerHealthStatus

func SetWorkerHealthStatus(workernode *WorkerNode, healthCondition *HealthCondition) HealthStatus

SetWorkerHealthStatus set workernode HealthStatus and HealthCondition

type HippoContainer

type HippoContainer struct {
	corev1.Container       `json:",inline"`
	ContainerHippoExterned `json:",inline"`
}

HippoContainer defines the extend hippo container fields

func (*HippoContainer) DeepCopy

func (in *HippoContainer) DeepCopy() *HippoContainer

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoContainer.

func (*HippoContainer) DeepCopyInto

func (in *HippoContainer) DeepCopyInto(out *HippoContainer)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*HippoContainer) Descriptor

func (*HippoContainer) Descriptor() ([]byte, []int)

func (*HippoContainer) Marshal

func (m *HippoContainer) Marshal() (dAtA []byte, err error)

func (*HippoContainer) MarshalTo

func (m *HippoContainer) MarshalTo(dAtA []byte) (int, error)

func (*HippoContainer) MarshalToSizedBuffer

func (m *HippoContainer) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HippoContainer) ProtoMessage

func (*HippoContainer) ProtoMessage()

func (*HippoContainer) Reset

func (m *HippoContainer) Reset()

func (*HippoContainer) Size

func (m *HippoContainer) Size() (n int)

func (*HippoContainer) String

func (this *HippoContainer) String() string
func (this *HealthCondition) String() string {
	if this == nil {
		return "nil"
	}
	keysForMetas := make([]string, 0, len(this.Metas))
	for k := range this.Metas {
		keysForMetas = append(keysForMetas, k)
	}
	github_com_gogo_protobuf_sortkeys.Strings(keysForMetas)
	mapStringForMetas := "map[string]string{"
	for _, k := range keysForMetas {
		mapStringForMetas += fmt.Sprintf("%v: %v,", k, this.Metas[k])
	}
	mapStringForMetas += "}"
	s := strings.Join([]string{`&HealthCondition{`,
		`Type:` + fmt.Sprintf("%v", this.Type) + `,`,
		`Status:` + fmt.Sprintf("%v", this.Status) + `,`,
		`LastTransitionTime:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.LastTransitionTime), "Time", "v1.Time", 1), `&`, ``, 1) + `,`,
		`Reason:` + fmt.Sprintf("%v", this.Reason) + `,`,
		`Message:` + fmt.Sprintf("%v", this.Message) + `,`,
		`LastLostTime:` + fmt.Sprintf("%v", this.LastLostTime) + `,`,
		`LostCount:` + fmt.Sprintf("%v", this.LostCount) + `,`,
		`Metas:` + mapStringForMetas + `,`,
		`Checked:` + fmt.Sprintf("%v", this.Checked) + `,`,
		`CompressedMetas:` + fmt.Sprintf("%v", this.CompressedMetas) + `,`,
		`Version:` + fmt.Sprintf("%v", this.Version) + `,`,
		`WorkerStatus:` + fmt.Sprintf("%v", this.WorkerStatus) + `,`,
		`}`,
	}, "")
	return s
}

func (*HippoContainer) Unmarshal

func (m *HippoContainer) Unmarshal(dAtA []byte) error

func (*HippoContainer) XXX_DiscardUnknown

func (m *HippoContainer) XXX_DiscardUnknown()

func (*HippoContainer) XXX_Marshal

func (m *HippoContainer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HippoContainer) XXX_Merge

func (m *HippoContainer) XXX_Merge(src proto.Message)

func (*HippoContainer) XXX_Size

func (m *HippoContainer) XXX_Size() int

func (*HippoContainer) XXX_Unmarshal

func (m *HippoContainer) XXX_Unmarshal(b []byte) error

type HippoPodSpec

type HippoPodSpec struct {
	corev1.PodSpec           `json:",inline"`
	Containers               []HippoContainer `json:"containers"`
	HippoPodSpecExtendFields `json:",inline"`
	HippoVolumes             []json.RawMessage `json:"hippoVolumes,omitempty"`
}

HippoPodSpec defines the hippo pod spec

func GetPodSpecFromTemplate

func GetPodSpecFromTemplate(hippoPodTemplate *HippoPodTemplate) (*HippoPodSpec, map[string]string, error)

GetPodSpecFromTemplate GetPodSpecFromTemplate

func (*HippoPodSpec) DeepCopy

func (in *HippoPodSpec) DeepCopy() *HippoPodSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoPodSpec.

func (*HippoPodSpec) DeepCopyInto

func (in *HippoPodSpec) DeepCopyInto(out *HippoPodSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*HippoPodSpec) Descriptor

func (*HippoPodSpec) Descriptor() ([]byte, []int)

func (*HippoPodSpec) Marshal

func (m *HippoPodSpec) Marshal() (dAtA []byte, err error)

func (*HippoPodSpec) MarshalTo

func (m *HippoPodSpec) MarshalTo(dAtA []byte) (int, error)

func (*HippoPodSpec) MarshalToSizedBuffer

func (m *HippoPodSpec) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HippoPodSpec) ProtoMessage

func (*HippoPodSpec) ProtoMessage()

func (*HippoPodSpec) Reset

func (m *HippoPodSpec) Reset()

func (*HippoPodSpec) Size

func (m *HippoPodSpec) Size() (n int)

func (*HippoPodSpec) String

func (this *HippoPodSpec) String() string

func (*HippoPodSpec) Unmarshal

func (m *HippoPodSpec) Unmarshal(dAtA []byte) error

func (*HippoPodSpec) XXX_DiscardUnknown

func (m *HippoPodSpec) XXX_DiscardUnknown()

func (*HippoPodSpec) XXX_Marshal

func (m *HippoPodSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HippoPodSpec) XXX_Merge

func (m *HippoPodSpec) XXX_Merge(src proto.Message)

func (*HippoPodSpec) XXX_Size

func (m *HippoPodSpec) XXX_Size() int

func (*HippoPodSpec) XXX_Unmarshal

func (m *HippoPodSpec) XXX_Unmarshal(b []byte) error

type HippoPodSpecExtend

type HippoPodSpecExtend struct {
	Containers               []ContainerHippoExternedWithName `json:"containers"`
	InstanceID               string                           `json:"instanceId,omitempty"`
	HippoPodSpecExtendFields `json:",inline"`
	Devices                  []Device          `json:"device,omitempty"`
	Volumes                  []json.RawMessage `json:"volumes,omitempty"`
}

HippoPodSpecExtend defines hippos pods spec extend

func (*HippoPodSpecExtend) DeepCopy

func (in *HippoPodSpecExtend) DeepCopy() *HippoPodSpecExtend

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoPodSpecExtend.

func (*HippoPodSpecExtend) DeepCopyInto

func (in *HippoPodSpecExtend) DeepCopyInto(out *HippoPodSpecExtend)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type HippoPodSpecExtendFields

type HippoPodSpecExtendFields struct {
	CpusetMode           string        `json:"cpusetMode,omitempty"`
	CPUShareNum          *int32        `json:"cpuShareNum,omitempty"`
	ContainerModel       string        `json:"containerModel,omitempty"`
	PackageInfos         []PackageInfo `json:"packageInfos,omitempty"`
	PredictDelayTime     int           `json:"predictDelayTime,omitempty"`
	RestartWithoutRemove *bool         `json:"restartWithoutRemove,omitempty"`
	NeedHippoMounts      *bool         `json:"needHippoMounts,omitempty"`
}

HippoPodSpecExtendFields HippoPodSpecExtendFields

func (*HippoPodSpecExtendFields) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoPodSpecExtendFields.

func (*HippoPodSpecExtendFields) DeepCopyInto

func (in *HippoPodSpecExtendFields) DeepCopyInto(out *HippoPodSpecExtendFields)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*HippoPodSpecExtendFields) Descriptor

func (*HippoPodSpecExtendFields) Descriptor() ([]byte, []int)

func (*HippoPodSpecExtendFields) Marshal

func (m *HippoPodSpecExtendFields) Marshal() (dAtA []byte, err error)

func (*HippoPodSpecExtendFields) MarshalTo

func (m *HippoPodSpecExtendFields) MarshalTo(dAtA []byte) (int, error)

func (*HippoPodSpecExtendFields) MarshalToSizedBuffer

func (m *HippoPodSpecExtendFields) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HippoPodSpecExtendFields) ProtoMessage

func (*HippoPodSpecExtendFields) ProtoMessage()

func (*HippoPodSpecExtendFields) Reset

func (m *HippoPodSpecExtendFields) Reset()

func (*HippoPodSpecExtendFields) Size

func (m *HippoPodSpecExtendFields) Size() (n int)

func (*HippoPodSpecExtendFields) String

func (this *HippoPodSpecExtendFields) String() string

func (*HippoPodSpecExtendFields) Unmarshal

func (m *HippoPodSpecExtendFields) Unmarshal(dAtA []byte) error

func (*HippoPodSpecExtendFields) XXX_DiscardUnknown

func (m *HippoPodSpecExtendFields) XXX_DiscardUnknown()

func (*HippoPodSpecExtendFields) XXX_Marshal

func (m *HippoPodSpecExtendFields) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HippoPodSpecExtendFields) XXX_Merge

func (m *HippoPodSpecExtendFields) XXX_Merge(src proto.Message)

func (*HippoPodSpecExtendFields) XXX_Size

func (m *HippoPodSpecExtendFields) XXX_Size() int

func (*HippoPodSpecExtendFields) XXX_Unmarshal

func (m *HippoPodSpecExtendFields) XXX_Unmarshal(b []byte) error

type HippoPodTemplate

type HippoPodTemplate struct {
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              HippoPodSpec `json:"spec,omitempty"`
}

HippoPodTemplate HippoPodTemplate

func GetHippoPodTemplate

func GetHippoPodTemplate(version *VersionPlan) (*HippoPodTemplate, error)

GetHippoPodTemplate get hippo template from raw template

func GetHippoPodTemplateFromPod

func GetHippoPodTemplateFromPod(pod interface{}) HippoPodTemplate

GetHippoPodTemplateFromPod GetHippoPodTemplateFromPod

func (*HippoPodTemplate) DeepCopy

func (in *HippoPodTemplate) DeepCopy() *HippoPodTemplate

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoPodTemplate.

func (*HippoPodTemplate) DeepCopyInto

func (in *HippoPodTemplate) DeepCopyInto(out *HippoPodTemplate)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*HippoPodTemplate) Descriptor

func (*HippoPodTemplate) Descriptor() ([]byte, []int)

func (*HippoPodTemplate) Marshal

func (m *HippoPodTemplate) Marshal() (dAtA []byte, err error)

func (*HippoPodTemplate) MarshalTo

func (m *HippoPodTemplate) MarshalTo(dAtA []byte) (int, error)

func (*HippoPodTemplate) MarshalToSizedBuffer

func (m *HippoPodTemplate) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HippoPodTemplate) ProtoMessage

func (*HippoPodTemplate) ProtoMessage()

func (*HippoPodTemplate) Reset

func (m *HippoPodTemplate) Reset()

func (*HippoPodTemplate) Size

func (m *HippoPodTemplate) Size() (n int)

func (*HippoPodTemplate) String

func (this *HippoPodTemplate) String() string

func (*HippoPodTemplate) Unmarshal

func (m *HippoPodTemplate) Unmarshal(dAtA []byte) error

func (*HippoPodTemplate) XXX_DiscardUnknown

func (m *HippoPodTemplate) XXX_DiscardUnknown()

func (*HippoPodTemplate) XXX_Marshal

func (m *HippoPodTemplate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HippoPodTemplate) XXX_Merge

func (m *HippoPodTemplate) XXX_Merge(src proto.Message)

func (*HippoPodTemplate) XXX_Size

func (m *HippoPodTemplate) XXX_Size() int

func (*HippoPodTemplate) XXX_Unmarshal

func (m *HippoPodTemplate) XXX_Unmarshal(b []byte) error

type HippoPrefrence

type HippoPrefrence struct {
	Scope *string `json:"scope,omitempty"`
	Type  *string `json:"type,omitempty"`
	TTL   *int32  `json:"ttl,omitempty"`
}

HippoPrefrence HippoPrefrence

func (*HippoPrefrence) DeepCopy

func (in *HippoPrefrence) DeepCopy() *HippoPrefrence

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoPrefrence.

func (*HippoPrefrence) DeepCopyInto

func (in *HippoPrefrence) DeepCopyInto(out *HippoPrefrence)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type HippoSlotID

type HippoSlotID struct {
	SlaveAddress string `json:"slave_address"`
	SlotID       int    `json:"slot_id"`
}

HippoSlotID defines hippo slot id

func (*HippoSlotID) DeepCopy

func (in *HippoSlotID) DeepCopy() *HippoSlotID

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HippoSlotID.

func (*HippoSlotID) DeepCopyInto

func (in *HippoSlotID) DeepCopyInto(out *HippoSlotID)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*HippoSlotID) Descriptor

func (*HippoSlotID) Descriptor() ([]byte, []int)

func (*HippoSlotID) Marshal

func (m *HippoSlotID) Marshal() (dAtA []byte, err error)

func (*HippoSlotID) MarshalTo

func (m *HippoSlotID) MarshalTo(dAtA []byte) (int, error)

func (*HippoSlotID) MarshalToSizedBuffer

func (m *HippoSlotID) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HippoSlotID) ProtoMessage

func (*HippoSlotID) ProtoMessage()

func (*HippoSlotID) Reset

func (m *HippoSlotID) Reset()

func (*HippoSlotID) Size

func (m *HippoSlotID) Size() (n int)

func (*HippoSlotID) String

func (this *HippoSlotID) String() string

func (*HippoSlotID) Unmarshal

func (m *HippoSlotID) Unmarshal(dAtA []byte) error

func (*HippoSlotID) XXX_DiscardUnknown

func (m *HippoSlotID) XXX_DiscardUnknown()

func (*HippoSlotID) XXX_Marshal

func (m *HippoSlotID) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HippoSlotID) XXX_Merge

func (m *HippoSlotID) XXX_Merge(src proto.Message)

func (*HippoSlotID) XXX_Size

func (m *HippoSlotID) XXX_Size() int

func (*HippoSlotID) XXX_Unmarshal

func (m *HippoSlotID) XXX_Unmarshal(b []byte) error

type IPNode

type IPNode struct {
	IP            string `json:"ip"`
	Score         int64  `json:"score"`
	Health        bool   `json:"health"`
	Checked       bool
	Warmup        bool
	InWarmup      bool
	StartWarmup   bool
	Lost          bool
	Failed        bool
	Port          []int32
	Weight        float32
	Valid         bool
	NewAdded      bool
	HealthMeta    map[string]string
	BizMeta       map[string]string
	ServiceMeta   string
	ServiceDetail string
}

IPNode means a node of service

func (*IPNode) DeepCopy

func (in *IPNode) DeepCopy() *IPNode

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IPNode.

func (*IPNode) DeepCopyInto

func (in *IPNode) DeepCopyInto(out *IPNode)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KeysMayBeAdjust

type KeysMayBeAdjust struct {
	VolumeKeys               []string `json:"volumeKeys,omitempty"`
	TolerationKeys           []string `json:"tolerationKeys,omitempty"`
	LableKeys                []string `json:"lableKeys,omitempty"`
	AnnotationKeys           []string `json:"annotationKeys,omitempty"`
	ResKeys                  []string `json:"resourceKeys,omitempty"`
	ContainerKeys            []string `json:"containerKeys,omitempty"`
	InitContainerKeys        []string `json:"initContainerKeys,omitempty"`
	WithWorkingDirContainers []string `json:"withWorkingDirContainers,omitempty"`
	SchedulerName            string   `json:"schedulerName,omitempty"`
}

KeysMayBeAdjust the keys c2 declared

func (*KeysMayBeAdjust) DeepCopy

func (in *KeysMayBeAdjust) DeepCopy() *KeysMayBeAdjust

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KeysMayBeAdjust.

func (*KeysMayBeAdjust) DeepCopyInto

func (in *KeysMayBeAdjust) DeepCopyInto(out *KeysMayBeAdjust)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LabelsCopy

type LabelsCopy struct {
	WorkerLabels      CopyTarget `json:"workerLabels,omitempty"`
	WorkerAnnotations CopyTarget `json:"workerAnnotations,omitempty"`
	PodLabels         CopyTarget `json:"podLabels,omitempty"`
	PodAnnotations    CopyTarget `json:"podAnnotations,omitempty"`
}

func (*LabelsCopy) DeepCopy

func (in *LabelsCopy) DeepCopy() *LabelsCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LabelsCopy.

func (*LabelsCopy) DeepCopyInto

func (in *LabelsCopy) DeepCopyInto(out *LabelsCopy)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LifecycleInstanceField

type LifecycleInstanceField struct {
	PostStart *corev1.LifecycleHandler `json:"postStart,omitempty" protobuf:"bytes,1,opt,name=postStart"`
}

LifecycleInstanceField used for compute instanceid

func (*LifecycleInstanceField) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LifecycleInstanceField.

func (*LifecycleInstanceField) DeepCopyInto

func (in *LifecycleInstanceField) DeepCopyInto(out *LifecycleInstanceField)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Lv7HealthCheckerConfig

type Lv7HealthCheckerConfig struct {
	// +optional
	LostCountThreshold int32 `json:"lostCountThreshold,omitempty" protobuf:"varint,4,opt,name=lostCountThreshold"`

	// 超时时间, 单位秒
	// +optional
	LostTimeout int64 `json:"lostTimeout,omitempty" protobuf:"varint,8,opt,name=lostTimeout"`

	// Path to access on the HTTP server.
	// +optional
	Path string `json:"path,omitempty"`

	// Name or number of the port to access on the container.
	// Number must be in the range 1 to 65535.
	// Name must be an IANA_SVC_NAME.
	Port intstr.IntOrString `json:"port" protobuf:"bytes,2,opt,name=port"`
}

Lv7HealthCheckerConfig lv7配置

func (*Lv7HealthCheckerConfig) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Lv7HealthCheckerConfig.

func (*Lv7HealthCheckerConfig) DeepCopyInto

func (in *Lv7HealthCheckerConfig) DeepCopyInto(out *Lv7HealthCheckerConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ObjKind

type ObjKind interface {
	GetKind() string
}

ObjKind get kind of obj

type PackageDetail

type PackageDetail struct {
	Status      string `json:"status"`
	PackageName string `json:"packageName"`
	Extra       Extra  `json:"extra"`
}

func (*PackageDetail) DeepCopy

func (in *PackageDetail) DeepCopy() *PackageDetail

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PackageDetail.

func (*PackageDetail) DeepCopyInto

func (in *PackageDetail) DeepCopyInto(out *PackageDetail)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PackageInfo

type PackageInfo struct {
	PacakgeType string `json:"pacakgeType"`
	PackageURI  string `json:"packageUri"`
}

PackageInfo extend spec, load package first

func (*PackageInfo) DeepCopy

func (in *PackageInfo) DeepCopy() *PackageInfo

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PackageInfo.

func (*PackageInfo) DeepCopyInto

func (in *PackageInfo) DeepCopyInto(out *PackageInfo)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PackageInfo) Descriptor

func (*PackageInfo) Descriptor() ([]byte, []int)

func (*PackageInfo) Marshal

func (m *PackageInfo) Marshal() (dAtA []byte, err error)

func (*PackageInfo) MarshalTo

func (m *PackageInfo) MarshalTo(dAtA []byte) (int, error)

func (*PackageInfo) MarshalToSizedBuffer

func (m *PackageInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PackageInfo) ProtoMessage

func (*PackageInfo) ProtoMessage()

func (*PackageInfo) Reset

func (m *PackageInfo) Reset()

func (*PackageInfo) Size

func (m *PackageInfo) Size() (n int)

func (*PackageInfo) String

func (this *PackageInfo) String() string

func (*PackageInfo) Unmarshal

func (m *PackageInfo) Unmarshal(dAtA []byte) error

func (*PackageInfo) XXX_DiscardUnknown

func (m *PackageInfo) XXX_DiscardUnknown()

func (*PackageInfo) XXX_Marshal

func (m *PackageInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PackageInfo) XXX_Merge

func (m *PackageInfo) XXX_Merge(src proto.Message)

func (*PackageInfo) XXX_Size

func (m *PackageInfo) XXX_Size() int

func (*PackageInfo) XXX_Unmarshal

func (m *PackageInfo) XXX_Unmarshal(b []byte) error

type PackageStatus

type PackageStatus struct {
	PackageDetails []PackageDetail `json:"packageDetails"`
}

func (*PackageStatus) DeepCopy

func (in *PackageStatus) DeepCopy() *PackageStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PackageStatus.

func (*PackageStatus) DeepCopyInto

func (in *PackageStatus) DeepCopyInto(out *PackageStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Patch

type Patch struct {
	Type  PatchStrategy   `json:"type"`
	Patch json.RawMessage `json:"patch"`
}

func (*Patch) DeepCopy

func (in *Patch) DeepCopy() *Patch

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Patch.

func (*Patch) DeepCopyInto

func (in *Patch) DeepCopyInto(out *Patch)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PatchStrategy

type PatchStrategy string

PatchStrategy PatchStrategy

const (
	PatchStrategyOverride PatchStrategy = "override"
	PatchStrategyMerge    PatchStrategy = "merge"
)

PatchStrategy

type PodInstanceField

type PodInstanceField struct {
	Containers     []ContainerInstanceField `json:"containers,omitempty"`
	ContainerModel string                   `json:"containerModel,omitempty"`
	PackageInfos   []PackageInfo            `json:"packageInfos,omitempty"`
	Volumes        []corev1.Volume          `json:"volumes,omitempty"`
	CpusetMode     string                   `json:"cpusetMode,omitempty"`
	CPUShareNum    *int32                   `json:"cpuShareNum,omitempty"`
}

PodInstanceField means container instance resource

func (*PodInstanceField) DeepCopy

func (in *PodInstanceField) DeepCopy() *PodInstanceField

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodInstanceField.

func (*PodInstanceField) DeepCopyInto

func (in *PodInstanceField) DeepCopyInto(out *PodInstanceField)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodResource

type PodResource struct {
	Containers   []ContainerResource `json:"containers" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=containers"`
	NodeSelector map[string]string   `json:"nodeSelector,omitempty" protobuf:"bytes,7,rep,name=nodeSelector"`
	NodeName     string              `json:"nodeName,omitempty" protobuf:"bytes,10,opt,name=nodeName"`
	Affinity     *corev1.Affinity    `json:"affinity,omitempty" protobuf:"bytes,18,opt,name=affinity"`
	Tolerations  []corev1.Toleration `json:"tolerations,omitempty" protobuf:"bytes,22,opt,name=tolerations"`
	Priority     *int32              `json:"priority,omitempty" protobuf:"bytes,25,opt,name=priority"`
	CpusetMode   string              `json:"cpusetMode,omitempty"`
	CPUShareNum  *int32              `json:"cpuShareNum,omitempty"`
}

PodResource means pod resource require

func (*PodResource) DeepCopy

func (in *PodResource) DeepCopy() *PodResource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodResource.

func (*PodResource) DeepCopyInto

func (in *PodResource) DeepCopyInto(out *PodResource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodStandbyStatus

type PodStandbyStatus struct {
	UseOrder     int64   `json:"useOrder,omitempty"`
	StandbyHours []int64 `json:"standbyHours,omitempty"`
}

PodStandbyStatus PodStandbyStatus

func (*PodStandbyStatus) DeepCopy

func (in *PodStandbyStatus) DeepCopy() *PodStandbyStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodStandbyStatus.

func (*PodStandbyStatus) DeepCopyInto

func (in *PodStandbyStatus) DeepCopyInto(out *PodStandbyStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodStandbyStatus) Descriptor

func (*PodStandbyStatus) Descriptor() ([]byte, []int)

func (*PodStandbyStatus) Marshal

func (m *PodStandbyStatus) Marshal() (dAtA []byte, err error)

func (*PodStandbyStatus) MarshalTo

func (m *PodStandbyStatus) MarshalTo(dAtA []byte) (int, error)

func (*PodStandbyStatus) MarshalToSizedBuffer

func (m *PodStandbyStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PodStandbyStatus) ProtoMessage

func (*PodStandbyStatus) ProtoMessage()

func (*PodStandbyStatus) Reset

func (m *PodStandbyStatus) Reset()

func (*PodStandbyStatus) Size

func (m *PodStandbyStatus) Size() (n int)

func (*PodStandbyStatus) String

func (this *PodStandbyStatus) String() string

func (*PodStandbyStatus) Unmarshal

func (m *PodStandbyStatus) Unmarshal(dAtA []byte) error

func (*PodStandbyStatus) XXX_DiscardUnknown

func (m *PodStandbyStatus) XXX_DiscardUnknown()

func (*PodStandbyStatus) XXX_Marshal

func (m *PodStandbyStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PodStandbyStatus) XXX_Merge

func (m *PodStandbyStatus) XXX_Merge(src proto.Message)

func (*PodStandbyStatus) XXX_Size

func (m *PodStandbyStatus) XXX_Size() int

func (*PodStandbyStatus) XXX_Unmarshal

func (m *PodStandbyStatus) XXX_Unmarshal(b []byte) error

type PodStatusExtend

type PodStatusExtend struct {
	InstanceID     string                         `json:"instanceId,omitempty"`
	CpusetMode     string                         `json:"cpusetMode,omitempty"`
	ContainerModel string                         `json:"containerModel,omitempty"`
	Containers     []ContainerStatusHippoExterned `json:"containers"`
}

PodStatusExtend defines the hippo container

func (*PodStatusExtend) DeepCopy

func (in *PodStatusExtend) DeepCopy() *PodStatusExtend

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodStatusExtend.

func (*PodStatusExtend) DeepCopyInto

func (in *PodStatusExtend) DeepCopyInto(out *PodStatusExtend)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PoolSpec

type PoolSpec struct {
	ZoomRatio int `json:"zoomRatio"`
	Addon     int `json:"addon"`
	SubTimeMs int `json:"subTimeMs"`
	Version   string
}

func GetPoolSpec

func GetPoolSpec(rs *RollingSet) (*PoolSpec, error)

func (*PoolSpec) DeepCopy

func (in *PoolSpec) DeepCopy() *PoolSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolSpec.

func (*PoolSpec) DeepCopyInto

func (in *PoolSpec) DeepCopyInto(out *PoolSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PoolStatus

type PoolStatus struct {
	Version string `json:"version"`
	Status  string `json:"status"`
}

func GetPoolStatus

func GetPoolStatus(rs *RollingSet) (*PoolStatus, error)

func (*PoolStatus) DeepCopy

func (in *PoolStatus) DeepCopy() *PoolStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolStatus.

func (*PoolStatus) DeepCopyInto

func (in *PoolStatus) DeepCopyInto(out *PoolStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ProcessStep

type ProcessStep string

ProcessStep describe the process step of controller

const (
	StepBegin                   ProcessStep = "StepBegin"
	StepProcessUpdateGracefully ProcessStep = "StepProcessUpdateGracefully"
	StepProcessPlan             ProcessStep = "StepProcessPlan"
	StepProcessHealthInfo       ProcessStep = "StepProcessHealthInfo"
	StepProcessServiceInfo      ProcessStep = "StepProcessServiceInfo"
	StepLost                    ProcessStep = "StepLost"
	StepToRelease               ProcessStep = "StepToRelease"
)

ProcessSteps

type ProvidorType

type ProvidorType string

ProvidorType is a type for ProvidorType

const (
	// ProvidorTypePod is a type for pod providor
	ProvidorTypePod ProvidorType = "pod"
	// ProvidorTypeReplica is a type for replica providor
	ProvidorTypeReplica ProvidorType = "replica"
)

type ReclaimWorkerNode

type ReclaimWorkerNode struct {
	WorkerNodeID string       `json:"workerNodeId"`
	SlotID       hippo.SlotId `json:"slotId"`
}

ReclaimWorkerNode ReclaimWorkerNode

func (*ReclaimWorkerNode) DeepCopy

func (in *ReclaimWorkerNode) DeepCopy() *ReclaimWorkerNode

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReclaimWorkerNode.

func (*ReclaimWorkerNode) DeepCopyInto

func (in *ReclaimWorkerNode) DeepCopyInto(out *ReclaimWorkerNode)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RecoverStrategy

type RecoverStrategy string

RecoverStrategy how to process with reclaiming worker node

type RegistryType

type RegistryType string

RegistryType define a service condition status type

const (
	ServiceNone      RegistryType = ""
	ServiceVipserver RegistryType = "Vipserver"
	ServiceCM2       RegistryType = "CM2"
	ServiceLVS       RegistryType = "LVS"
	ServiceSLB       RegistryType = "SLB"
	ServiceVPCSLB    RegistryType = "VPC_SLB"
	ServiceALB       RegistryType = "ALB"
	ServiceArmory    RegistryType = "Armory"
	ServiceSkyline   RegistryType = "Skyline"
	ServiceAntvip    RegistryType = "Antvip"
	ServiceMesh      RegistryType = "ServiceMesh"
	ServiceGeneral   RegistryType = "General"
)

These are valid conditions of a service.

type Replica

type Replica struct {
	WorkerNode
	Backup WorkerNode
	Gang   []Replica
}

Replica is a specification for a Replica resource

func MergeReplica

func MergeReplica(replicas ...[]*Replica) []*Replica

func SubReplicas

func SubReplicas(src []*Replica, sub []*Replica) []*Replica

SubReplicas sub replicas

func (*Replica) DeepCopy

func (in *Replica) DeepCopy() *Replica

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Replica.

func (*Replica) DeepCopyInto

func (in *Replica) DeepCopyInto(out *Replica)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Replica) GetDeletionCost

func (o *Replica) GetDeletionCost() int

GetDeletionCost returns Replica status score The implementation of the Node interface

func (*Replica) GetDependencyReady

func (o *Replica) GetDependencyReady() bool

GetDependencyReady returns Replica status dependencyReady The implementation of the GroupNode interface

func (*Replica) GetGroupVersion

func (o *Replica) GetGroupVersion() string

GetGroupVersion returns Replica spec group version The implementation of the GroupNode interface

func (*Replica) GetKind

func (o *Replica) GetKind() string

GetKind get kind of obj

func (*Replica) GetScore

func (o *Replica) GetScore() int

GetScore returns Replica status score The implementation of the Node interface

func (*Replica) GetUpdateScore

func (o *Replica) GetUpdateScore() int

GetUpdateScore returns Replica score when upgrading

func (*Replica) GetVersion

func (o *Replica) GetVersion() string

GetVersion returns Replica spec version The implementation of the Node interface

func (*Replica) GetVersionPlan

func (o *Replica) GetVersionPlan() interface{}

GetVersionPlan returns Replica spec version plan The implementation of the Node interface

func (*Replica) IsEmpty

func (o *Replica) IsEmpty() bool

IsEmpty returns whether Replica is empty The implementation of the Node interface

func (*Replica) IsGangReplica

func (o *Replica) IsGangReplica() bool

IsGangReplica returns whether Replica is a Gang

func (*Replica) IsReady

func (o *Replica) IsReady() bool

IsReady returns whether Replica is ready The implementation of the Node interface

func (*Replica) IsRelease

func (o *Replica) IsRelease() bool

IsRelease returns whether Replica is release The implementation of the Node interface

func (*Replica) SetDependencyReady

func (o *Replica) SetDependencyReady(dependencyReady bool)

SetDependencyReady set Replica status dependencyReady The implementation of the GroupNode interface

func (*Replica) SetVersion

func (o *Replica) SetVersion(version string, versionPlan interface{})

SetVersion set Replica spec version and spec version plan The implementation of the Node interface

func (*Replica) Stop

func (o *Replica) Stop()

Stop function stop a Replica The implementation of the Node interface

type ReplicaStatus

type ReplicaStatus struct {
	Name                string             `json:"name"`
	CurWorkerNode       *ReplicaWorkerNode `json:"curWorkerNode,omitempty"`
	BackupWorkerNode    *ReplicaWorkerNode `json:"backupWorkerNode,omitempty"`
	Subrs               string             `json:"subrs"`
	CurTargetVersion    string             `json:"curTargetVersion"`
	BackupTargetVersion string             `json:"backupTargetVersion"`
	Detail              Detail             `json:"detail"`
}

ReplicaStatus is a pair of workernode status

func (*ReplicaStatus) DeepCopy

func (in *ReplicaStatus) DeepCopy() *ReplicaStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicaStatus.

func (*ReplicaStatus) DeepCopyInto

func (in *ReplicaStatus) DeepCopyInto(out *ReplicaStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ReplicaWorkerNode

type ReplicaWorkerNode struct {
	*WorkerNodeStatus `json:",inline"`
	TargetVersion     string `json:"targetVersion"`
}

func (*ReplicaWorkerNode) DeepCopy

func (in *ReplicaWorkerNode) DeepCopy() *ReplicaWorkerNode

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicaWorkerNode.

func (*ReplicaWorkerNode) DeepCopyInto

func (in *ReplicaWorkerNode) DeepCopyInto(out *ReplicaWorkerNode)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RollingSet

type RollingSet struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   RollingSetSpec   `json:"spec"`
	Status RollingSetStatus `json:"status"`
}

RollingSet is a specification for a RollingSet resource

func (*RollingSet) CreatePod

func (r *RollingSet) CreatePod() (*corev1.Pod, error)

CreatePod CreatePod

func (*RollingSet) DeepCopy

func (in *RollingSet) DeepCopy() *RollingSet

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingSet.

func (*RollingSet) DeepCopyInto

func (in *RollingSet) DeepCopyInto(out *RollingSet)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*RollingSet) DeepCopyObject

func (in *RollingSet) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*RollingSet) GetCPU

func (r *RollingSet) GetCPU() int32

GetCPU GetCPU

func (*RollingSet) GetCarbonRoleName

func (r *RollingSet) GetCarbonRoleName() string

GetCarbonRoleName GetCarbonRoleName

func (*RollingSet) GetDependencyLevel

func (r *RollingSet) GetDependencyLevel() int32

GetDependencyLevel GetDependencyLevel

func (*RollingSet) GetKind

func (o *RollingSet) GetKind() string

GetKind get kind of obj

func (*RollingSet) GetLatestVersionRatio

func (r *RollingSet) GetLatestVersionRatio(version string) int32

GetLatestVersionRatio GetLatestVersionRatio

func (*RollingSet) GetName

func (r *RollingSet) GetName() string

GetName GetName

func (*RollingSet) GetRawReplicas

func (r *RollingSet) GetRawReplicas() int32

GetRawReplicas GetRawReplicas

func (*RollingSet) GetReplicas

func (r *RollingSet) GetReplicas() int32

GetReplicas GetReplicas

func (*RollingSet) GetResourceVersionStatus

func (r *RollingSet) GetResourceVersionStatus() map[string]*rollalgorithm.ResourceVersionStatus

GetResourceVersionStatus GetResourceVersionStatus

func (*RollingSet) GetScaleParameters

func (r *RollingSet) GetScaleParameters() *ScaleParameters

GetScaleParameters GetScaleParameters

func (*RollingSet) GetScaleStrategy

func (r *RollingSet) GetScaleStrategy() *app.DeploymentStrategy

GetScaleStrategy GetScaleStrategy

func (*RollingSet) GetSchedulePlan

func (r *RollingSet) GetSchedulePlan() rollalgorithm.SchedulePlan

GetSchedulePlan GetSchedulePlan

func (*RollingSet) GetTotal

func (r *RollingSet) GetTotal() int32

GetTotal ...

func (*RollingSet) GetVersionStatus

func (r *RollingSet) GetVersionStatus() map[string]*rollalgorithm.VersionStatus

GetVersionStatus GetVersionStatus

func (*RollingSet) IsRollingSetInRestarting

func (r *RollingSet) IsRollingSetInRestarting() bool

IsRollingSetInRestarting IsRollingSetInRestarting

func (*RollingSet) RollingSetNeedGracefullyRestarting

func (r *RollingSet) RollingSetNeedGracefullyRestarting() bool

RollingSetNeedGracefullyRestarting RollingSetNeedGracefullyRestarting

type RollingSetList

type RollingSetList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []RollingSet `json:"items"`
}

RollingSetList is a list of RollingSet resources

func (*RollingSetList) DeepCopy

func (in *RollingSetList) DeepCopy() *RollingSetList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingSetList.

func (*RollingSetList) DeepCopyInto

func (in *RollingSetList) DeepCopyInto(out *RollingSetList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*RollingSetList) DeepCopyObject

func (in *RollingSetList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type RollingSetSpec

type RollingSetSpec struct {
	// Label selector for pods. Existing Replicas whose pods are
	// selected by this will be the ones affected by this rollingset.
	// It must match the pod template's labels.
	Selector *metav1.LabelSelector `json:"selector" protobuf:"bytes,2,opt,name=selector"`

	// config for schedule
	rollalgorithm.SchedulePlan `json:",inline"`
	// ScaleSchedulePlan ScaleConfig 迁移到 Capacity里去
	ScaleSchedulePlan *ScaleSchedulePlan  `json:"scaleSchedulePlan,omitempty"`
	ScaleConfig       *ScaleConfig        `json:"scaleConfig,omitempty"`
	Capacity          Capacity            `json:"capacity,omitempty"`
	DaemonSetReplicas *intstr.IntOrString `json:"daemonSetReplicas"`
	// latestVersionRatio of subRS
	SubRSLatestVersionRatio *map[string]int32 `json:"subrsLatestVersionRatio"`
	// the owner of subRS
	GroupRS *string `json:"groupRS"`

	// ResVersion means the signature of Resources.
	ResVersion string `json:"resVersion"`
	// Version means the signature of VersionPlan.
	Version string `json:"version"`
	// InstanceID to mark restarting
	InstanceID string `json:"instanceID"`
	// config for resource and progress
	VersionPlan `json:",inline"`

	// CheckSum means the signature of spec.
	CheckSum string `json:"checkSum"`

	//健康检查配置
	HealthCheckerConfig *HealthCheckerConfig `json:"healthCheckerConfig"`
	// 弹性副本数预测 key hour,val replicas
	PredictInfo       string                  `json:"predictInfo,omitempty"`
	GangVersionPlan   map[string]*VersionPlan `json:"gangVersionPlan,omitempty"`
	SubrsRatioVersion string                  `json:"subrsRatioVersion,omitempty"`
	SubrsBlackList    []string                `json:"subrsBlackList,omitempty"`
}

RollingSetSpec is the spec for a RollingSetSpec resource

func (*RollingSetSpec) DeepCopy

func (in *RollingSetSpec) DeepCopy() *RollingSetSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingSetSpec.

func (*RollingSetSpec) DeepCopyInto

func (in *RollingSetSpec) DeepCopyInto(out *RollingSetSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RollingSetStatus

type RollingSetStatus struct {
	Complete     bool `json:"complete"`
	ServiceReady bool `json:"serviceReady"`

	Rolling  bool `json:"rolling,omitempty"`
	Reducing bool `json:"reducing,omitempty"`
	// Total number of non-terminated Replica targeted by this rollingset (their labels match the selector).
	// +optional
	Replicas int32 `json:"replicas"`
	Workers  int32 `json:"workers"`

	ActiveReplicas             int32            `json:"activeReplicas"`
	StandbyReplicas            int32            `json:"standbyReplicas"`
	ColdStandbys               int32            `json:"coldStandbys"`
	WarmStandbys               int32            `json:"warmStandbys"`
	HotStandbys                int32            `json:"hotStandbys"`
	WorkerModeMisMatchReplicas int32            `json:"workerModeMisMatchReplicas"`
	UnAssignedStandbyReplicas  int32            `json:"unAssignedStandbyReplicas"`
	UpdatedReplicas            int32            `json:"updatedReplicas"`
	ReadyReplicas              int32            `json:"readyReplicas"`
	AvailableReplicas          int32            `json:"availableReplicas"`
	UnavailableReplicas        int32            `json:"unavailableReplicas"`
	AllocatedReplicas          int32            `json:"allocatedReplicas,omitempty"`
	ReleasingReplicas          int32            `json:"releasingReplicas"`
	ReleasingWorkers           int32            `json:"releasingWorkers"`
	UnAssignedWorkers          map[string]int32 `json:"unAssignedWorkers"`

	// rollingset 下的version数,包含rollingset和replica
	// +optional
	VersionCount int32 `json:"versionCount"`

	// Represents the latest available observations of a rollingset's current state.
	// +patchMergeKey=type
	// +patchStrategy=merge
	Conditions []app.DeploymentCondition `json:"conditions,omitempty"`

	//LastUpdateStatusTime 最近一次更新时间
	LastUpdateStatusTime metav1.Time `json:"lastUpdateStatusTime,omitempty"`

	//GroupVersionStatusMap 每个版本的服务状态,key是ShardGroupVersion
	GroupVersionStatusMap GroupVersionStatusMap `json:"groupVersionStatusMap,omitempty"`

	//ResourceVersionStatusMap 每个版本的服务状态,key是ShardGroupVersion
	ResourceVersionStatusMap map[string]*rollalgorithm.ResourceVersionStatus `json:"resourceVersionStatusMap,omitempty"`
	//Version 当前正在处理的version
	Version        string `json:"version"`
	UserDefVersion string `json:"userDefVersion,omitempty"`
	// InstanceID to mark restarting
	InstanceID            string                 `json:"instanceID"`
	UncompleteReplicaInfo map[string]ProcessStep `json:"uncompleteReplicaInfo"`

	// subrs 中每个Rollingset 的versionStatusMap, key是subrsName, value 是这个subrs 的GroupVersionStatusMap
	SubrsVersionStatusMap SubrsVersionStatusMap `json:"subrsVersionStatusMap,omitempty"`
	SubrsTargetReplicas   map[string]*int32     `json:"subrsTargetReplicas,omitempty"`
	// LabelSelector is label selectors for query over pods that should match the replica count used by HPA.
	LabelSelector      string          `json:"labelSelector,omitempty"`
	SpotInstanceStatus SpotStatus      `json:"spotInstanceStatus"`
	SubrsRatioVersion  string          `json:"subrsRatioVersion"`
	SubrsTargetReached map[string]bool `json:"subrsTargetReached,omitempty"`
}

RollingSetStatus is the status for a RollingSet resource

func (*RollingSetStatus) DeepCopy

func (in *RollingSetStatus) DeepCopy() *RollingSetStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingSetStatus.

func (*RollingSetStatus) DeepCopyInto

func (in *RollingSetStatus) DeepCopyInto(out *RollingSetStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RollingsetHippoExterned

type RollingsetHippoExterned struct {
	ApplicationID string `json:"applicationId"`
	QuotaGroupID  string `json:"quotaGroupId"`
}

RollingsetHippoExterned defines the hippo extend fields

func (*RollingsetHippoExterned) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingsetHippoExterned.

func (*RollingsetHippoExterned) DeepCopyInto

func (in *RollingsetHippoExterned) DeepCopyInto(out *RollingsetHippoExterned)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RollingsetPatch

type RollingsetPatch struct {
	FiberId string          `json:"fiberId"`
	RoleId  string          `json:"roleId"`
	Patch   json.RawMessage `json:"patch"`
}

func (*RollingsetPatch) DeepCopy

func (in *RollingsetPatch) DeepCopy() *RollingsetPatch

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingsetPatch.

func (*RollingsetPatch) DeepCopyInto

func (in *RollingsetPatch) DeepCopyInto(out *RollingsetPatch)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RollingsetVerbose

type RollingsetVerbose struct {
	SubrsMetas SubrsMetas        `json:"subrsMetas"`
	Status     *RollingSetStatus `json:"status"`
	Replicas   []*ReplicaStatus  `json:"replicas"`
}

RollingsetVerbose ...

func (*RollingsetVerbose) DeepCopy

func (in *RollingsetVerbose) DeepCopy() *RollingsetVerbose

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RollingsetVerbose.

func (*RollingsetVerbose) DeepCopyInto

func (in *RollingsetVerbose) DeepCopyInto(out *RollingsetVerbose)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScaleConfig

type ScaleConfig struct {
	Enable bool `json:"enable"`
}

ScaleConfig ScaleConfig

func (*ScaleConfig) DeepCopy

func (in *ScaleConfig) DeepCopy() *ScaleConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScaleConfig.

func (*ScaleConfig) DeepCopyInto

func (in *ScaleConfig) DeepCopyInto(out *ScaleConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScaleParameters

type ScaleParameters struct {
	ActiveReplicas         int32
	StandByReplicas        int32
	StandByRatioMap        map[WorkerModeType]int
	ScalerResourcePoolName string
}

ScaleParameters ScaleParameters

func (*ScaleParameters) DeepCopy

func (in *ScaleParameters) DeepCopy() *ScaleParameters

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScaleParameters.

func (*ScaleParameters) DeepCopyInto

func (in *ScaleParameters) DeepCopyInto(out *ScaleParameters)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScaleSchedulePlan

type ScaleSchedulePlan struct {
	//Replicas 目标总数, 不能为nil
	Replicas *int32 `json:"replicas"`

	// The rollingset strategy to use to replace existing replica with new ones.
	// +optional
	// +patchStrategy=retainKeys
	Strategy app.DeploymentStrategy `json:"strategy,omitempty"`

	RecycleMode WorkerModeType `json:"recycleMode,omitempty"`

	RecyclePool string `json:"recyclePool,omitempty"`

	SmoothRolling bool `json:"smoothRolling,omitempty"`

	// vpa scale
	ResourceRequests corev1.ResourceList `json:"ResourceRequests,omitempty"`
}

ScaleSchedulePlan ScaleSchedulePlan

func (*ScaleSchedulePlan) DeepCopy

func (in *ScaleSchedulePlan) DeepCopy() *ScaleSchedulePlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScaleSchedulePlan.

func (*ScaleSchedulePlan) DeepCopyInto

func (in *ScaleSchedulePlan) DeepCopyInto(out *ScaleSchedulePlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SceneNode

type SceneNode struct {
	Name   string `json:"name"`
	Status int    `json:"status"`
	IP     string `json:"ip"`
}

func (*SceneNode) DeepCopy

func (in *SceneNode) DeepCopy() *SceneNode

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SceneNode.

func (*SceneNode) DeepCopyInto

func (in *SceneNode) DeepCopyInto(out *SceneNode)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScheduleStatusExtend

type ScheduleStatusExtend struct {
	HealthScore int32 `json:"healthScore"`
	DeclareTime int64 `json:"declareTime"`
	//ScheduleDiagnosis string      `json:"scheduleDiagnosis"`
	RequirementID    string      `json:"app.hippo.io/requirementId"`
	RequirementMatch bool        `json:"app.hippo.io/requirementMatch"`
	NodeDomain       string      `json:"nodeDomain"`
	SlotID           HippoSlotID `json:"slotId"`
	UID              string      `json:"uid"`
	NodeName         string      `json:"nodeName"`
}

ScheduleStatusExtend hippo extend fileds

func (*ScheduleStatusExtend) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScheduleStatusExtend.

func (*ScheduleStatusExtend) DeepCopyInto

func (in *ScheduleStatusExtend) DeepCopyInto(out *ScheduleStatusExtend)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ServiceCondition

type ServiceCondition struct {
	// Type of worker node condition.
	Type RegistryType `json:"type"`
	// ServiceName of service to publish.
	ServiceName string `json:"serviceName"`
	// Status of the condition, one of True, False, Unknown.
	Status corev1.ConditionStatus `json:"status"`
	Score  int64                  `json:"score"`
	// The last time the condition transitioned from one status to another.
	// +optional
	LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"`
	// The reason for the condition's last transition.
	// +optional
	Reason string `json:"reason,omitempty"`
	// A human readable message indicating details about the transition.
	// +optional
	Message       string `json:"message,omitempty"`
	InWarmup      bool   `json:"inWarmup,omitempty"`
	DeleteCount   int    `json:"deleteCount,omitempty"`
	Name          string `json:"name"`
	StartWarmup   bool   `json:"startWarmup,omitempty"`
	Version       string `json:"version"`
	ServiceDetail string `json:"serviceDetail,omitempty"`
}

ServiceCondition describes the service publish state of a worker at a certain point.

func (*ServiceCondition) DeepCopy

func (in *ServiceCondition) DeepCopy() *ServiceCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServiceCondition.

func (*ServiceCondition) DeepCopyInto

func (in *ServiceCondition) DeepCopyInto(out *ServiceCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ServiceCondition) Descriptor

func (*ServiceCondition) Descriptor() ([]byte, []int)

func (*ServiceCondition) Marshal

func (m *ServiceCondition) Marshal() (dAtA []byte, err error)

func (*ServiceCondition) MarshalTo

func (m *ServiceCondition) MarshalTo(dAtA []byte) (int, error)

func (*ServiceCondition) MarshalToSizedBuffer

func (m *ServiceCondition) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ServiceCondition) ProtoMessage

func (*ServiceCondition) ProtoMessage()

func (*ServiceCondition) Reset

func (m *ServiceCondition) Reset()

func (*ServiceCondition) Size

func (m *ServiceCondition) Size() (n int)

func (*ServiceCondition) String

func (this *ServiceCondition) String() string

func (*ServiceCondition) Unmarshal

func (m *ServiceCondition) Unmarshal(dAtA []byte) error

func (*ServiceCondition) XXX_DiscardUnknown

func (m *ServiceCondition) XXX_DiscardUnknown()

func (*ServiceCondition) XXX_Marshal

func (m *ServiceCondition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ServiceCondition) XXX_Merge

func (m *ServiceCondition) XXX_Merge(src proto.Message)

func (*ServiceCondition) XXX_Size

func (m *ServiceCondition) XXX_Size() int

func (*ServiceCondition) XXX_Unmarshal

func (m *ServiceCondition) XXX_Unmarshal(b []byte) error

type ServicePublisher

type ServicePublisher struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   ServicePublisherSpec   `json:"spec"`
	Status ServicePublisherStatus `json:"status"`
}

ServicePublisher is a specification for a Publisher for a registry resource

func (*ServicePublisher) DeepCopy

func (in *ServicePublisher) DeepCopy() *ServicePublisher

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePublisher.

func (*ServicePublisher) DeepCopyInto

func (in *ServicePublisher) DeepCopyInto(out *ServicePublisher)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ServicePublisher) DeepCopyObject

func (in *ServicePublisher) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ServicePublisherList

type ServicePublisherList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []ServicePublisher `json:"items"`
}

ServicePublisherList is a list of Replica ServicePublisher

func (*ServicePublisherList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePublisherList.

func (*ServicePublisherList) DeepCopyInto

func (in *ServicePublisherList) DeepCopyInto(out *ServicePublisherList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ServicePublisherList) DeepCopyObject

func (in *ServicePublisherList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ServicePublisherSpec

type ServicePublisherSpec struct {
	// Selector is a label query over pods that should match the replica count.
	// Label keys and values that must match in order to be controlled by this replica set.
	// It must match the pod template's labels.
	// More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors
	Selector map[string]string `json:"selector"`

	ServiceName  string          `json:"serviceName"`
	MetaStr      string          `json:"metaStr"`
	Type         RegistryType    `json:"registryType"`
	RegistryConf json.RawMessage `json:"registryConf"`

	SoftDelete bool `json:"softDelete"`
	// NewVersionRatio means the traffic ratio of new version replicas of a rollingset.
	// +optional
	NewVersionRatio int32 `json:"newVersionRatio,omitempty"`

	// HasBackup means if this service can cut .
	// +optional
	HasBackup bool `json:"hasBackup,omitempty"`
	// Cluster used for .
	// +optional
	Cluster string `json:"cluster"`
	// Disable means cut this service, of if HasBackup is true, Disable can be true.
	// +optional
	Disable bool `json:"disable,omitempty"`
	// Mirror means is this service a mirror of other cluster,
	// if mirror is true ,this publisher only used for cut service of other cluster.
	// +optional
	Mirror bool `json:"mirror,omitempty"`
}

ServicePublisherSpec is the Spec for a ServicePublisher resource

func (*ServicePublisherSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePublisherSpec.

func (*ServicePublisherSpec) DeepCopyInto

func (in *ServicePublisherSpec) DeepCopyInto(out *ServicePublisherSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ServicePublisherStatus

type ServicePublisherStatus struct {
	// IpList means the published ips of this service
	IPList  []IPNode `json:"ipList,omitempty"`
	IPs     []string `json:"ips,omitempty"`
	Message string   `json:"message"`
	Reason  string   `json:"reason"`
	//LastUpdateStatusTime 最近一次更新时间
	LastUpdateStatusTime metav1.Time `json:"lastUpdateStatusTime,omitempty"`
}

ServicePublisherStatus is the Status for a ServicePublisher resource

func (*ServicePublisherStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePublisherStatus.

func (*ServicePublisherStatus) DeepCopyInto

func (in *ServicePublisherStatus) DeepCopyInto(out *ServicePublisherStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ServiceStatus

type ServiceStatus string

ServiceStatus define a service status type

const (
	ServiceUnKnown       ServiceStatus = "SVT_UNKNOWN"
	ServiceUnAvailable   ServiceStatus = "SVT_UNAVAILABLE"
	ServicePartAvailable ServiceStatus = "SVT_PART_AVAILABLE"
	ServiceAvailable     ServiceStatus = "SVT_AVAILABLE"
)

These are the valid statuses of worker service health.

func DeleteWorkerServiceHealthCondition

func DeleteWorkerServiceHealthCondition(worker *WorkerNode, name string, serviceErr error) ServiceStatus

DeleteWorkerServiceHealthCondition delete a service condition

func GetServiceStatusFromCondition

func GetServiceStatusFromCondition(worker *WorkerNode) ServiceStatus

GetServiceStatusFromCondition get service health status

func SetWorkerServiceHealthCondition

func SetWorkerServiceHealthCondition(worker *WorkerNode, service *ServicePublisher,
	serviceDetail string, status v1.ConditionStatus, score int64, reason, message string, inWarmup, startWarmup bool) ServiceStatus

SetWorkerServiceHealthCondition set or add a service condition

func SyncWorkerServiceHealthStatus

func SyncWorkerServiceHealthStatus(worker *WorkerNode) ServiceStatus

SyncWorkerServiceHealthStatus get service health status and sync to worker status

type ShardDeployType

type ShardDeployType string

ShardDeployType is the type for shardDeploy

const (
	// RollingSetType for rollingSet rolling
	RollingSetType ShardDeployType = "rollingSet"
	// DeploymentType for deployment rolling
	DeploymentType ShardDeployType = "deployment"
)

type ShardGroup

type ShardGroup struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              ShardGroupSpec   `json:"spec"`
	Status            ShardGroupStatus `json:"status"`
}

ShardGroup is a specification for shardgroup resource

func (*ShardGroup) DeepCopy

func (in *ShardGroup) DeepCopy() *ShardGroup

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardGroup.

func (*ShardGroup) DeepCopyInto

func (in *ShardGroup) DeepCopyInto(out *ShardGroup)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ShardGroup) DeepCopyObject

func (in *ShardGroup) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*ShardGroup) GetKind

func (o *ShardGroup) GetKind() string

GetKind get kind of obj

type ShardGroupList

type ShardGroupList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`
	Items           []ShardGroup `json:"items"`
}

ShardGroupList is a list of ShardGroup resources

func (*ShardGroupList) DeepCopy

func (in *ShardGroupList) DeepCopy() *ShardGroupList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardGroupList.

func (*ShardGroupList) DeepCopyInto

func (in *ShardGroupList) DeepCopyInto(out *ShardGroupList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ShardGroupList) DeepCopyObject

func (in *ShardGroupList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ShardGroupPhase

type ShardGroupPhase string

ShardGroupPhase is the phase of the shardGroup resouce

const (
	// ShardGroupUpdating means the shardgroup is updating
	ShardGroupUpdating ShardGroupPhase = "Updating"
	// ShardGroupRolling means the shardgroup is updating
	ShardGroupRolling ShardGroupPhase = "Rolling"
	// ShardGroupRunning means that the rolling is done
	ShardGroupRunning ShardGroupPhase = "Running"
	// ShardGroupFailed means that the rolling update is failed
	ShardGroupFailed ShardGroupPhase = "Failed"
	// ShardGroupUnknown means that for some reason the state of the shardGroup could not be obtained.
	ShardGroupUnknown ShardGroupPhase = "Unknown"
)

type ShardGroupSignSpec

type ShardGroupSignSpec struct {
	RestartAfterResourceChange *bool                        `json:"restartAfterResourceChange,omitempty"`
	ShardTemplates             map[string]ShardSignTemplate `json:"shardTemplates,omitempty"`
}

ShardGroupSignSpec is the spec for sign shardGroup

func (*ShardGroupSignSpec) DeepCopy

func (in *ShardGroupSignSpec) DeepCopy() *ShardGroupSignSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardGroupSignSpec.

func (*ShardGroupSignSpec) DeepCopyInto

func (in *ShardGroupSignSpec) DeepCopyInto(out *ShardGroupSignSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ShardGroupSpec

type ShardGroupSpec struct {
	Selector       *metav1.LabelSelector `json:"selector,omitempty"`
	RollingVersion string                `json:"rollingVersion,omitempty"`
	Paused         bool                  `json:"paused,omitempty"`

	LatestPercent  *int32              `json:"latestPercent,omitempty"` //对齐目标比例,取值范围1-100
	MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty"`
	MaxSurge       *intstr.IntOrString `json:"maxSurge,omitempty"`

	// scaleConfig
	ScaleStrategy   *app.DeploymentStrategy `json:"scaleStrategy,omitempty"`
	ScaleConfig     *ScaleConfig            `json:"scaleConfig,omitempty"`
	RollingStrategy string                  `json:"rollingStrategy,omitempty"`

	AppStopCmd      string `json:"appStopCmd,omitempty"`
	AppStopTimeout  int32  `json:"appStopTimeout,omitempty"`
	AppReadyTimeout int64  `json:"appReadyTimeout,omitempty"`
	AutoRecovery    bool   `json:"autoRecovery,omitempty"`

	// from where to allocate entity. for example, "replica","rollingset-name" or  "pod",""
	WorkerSchedulePlan `json:",inline"`

	// UpdatingGracefully means is need to unpublish before update
	UpdatingGracefully         *bool `json:"updatingGracefully,omitempty"`
	RestartAfterResourceChange *bool `json:"restartAfterResourceChange,omitempty"`

	ShardTemplates           map[string]ShardTemplate   `json:"shardTemplates,omitempty"`
	CompressedShardTemplates string                     `json:"compressedShardTemplates,omitempty"`
	ShardDeployStrategy      ShardDeployType            `json:"strategy,omitempty"`
	Extension                map[string]json.RawMessage `json:"extension,omitempty"`

	UpdatePlanTimestamp int64 `json:"updatePlanTimestamp,omitempty"`
}

ShardGroupSpec is the spec for a ShardGroup resource

func (*ShardGroupSpec) DeepCopy

func (in *ShardGroupSpec) DeepCopy() *ShardGroupSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardGroupSpec.

func (*ShardGroupSpec) DeepCopyInto

func (in *ShardGroupSpec) DeepCopyInto(out *ShardGroupSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ShardGroupSpec) GetStrategy

func (s *ShardGroupSpec) GetStrategy() appsv1.DeploymentStrategy

GetStrategy GetStrategy

type ShardGroupStatus

type ShardGroupStatus struct {
	// ObservedGeneration reflects the generation of the most recently observed shardGroup
	// +optional
	ObservedGeneration int64 `json:"observedGeneration"`
	// ShardGroupVersion is the version for shardGroup
	ShardGroupVersion string `json:"shardGroupVersion"`
	// phase of shardGroup status
	Phase ShardGroupPhase `json:"phase"` // Updating Running Failed
	// return all the rollingset or deployment name owned by shardGroup
	ShardNames []string `json:"shardNames,omitempty"`
	// 完成过目标的列,区别于新建列
	OnceCompletedShardNames []string `json:"onceCompletedShardNames,omitempty"`
	Complete                bool     `json:"complete,omitempty"`
	// update time by shardGroup resource
	LastUpdateStatusTime metav1.Time `json:"lastUpdateStatusTime,omitempty"`
}

ShardGroupStatus is the status for a ShardGroup resour

func (*ShardGroupStatus) DeepCopy

func (in *ShardGroupStatus) DeepCopy() *ShardGroupStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardGroupStatus.

func (*ShardGroupStatus) DeepCopyInto

func (in *ShardGroupStatus) DeepCopyInto(out *ShardGroupStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ShardSignSpec

type ShardSignSpec struct {
	Signature   string           `json:"signature,omitempty"`
	Cm2TopoInfo string           `json:"cm2TopoInfo,omitempty"`
	Template    HippoPodTemplate `json:"template"`
}

ShardSignSpec is the spec for shard resource

func (*ShardSignSpec) DeepCopy

func (in *ShardSignSpec) DeepCopy() *ShardSignSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardSignSpec.

func (*ShardSignSpec) DeepCopyInto

func (in *ShardSignSpec) DeepCopyInto(out *ShardSignSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ShardSignTemplate

type ShardSignTemplate struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              ShardSignSpec `json:"shardSpec,omitempty"`
}

ShardSignTemplate is used for the sign of the shardGroup

func (*ShardSignTemplate) DeepCopy

func (in *ShardSignTemplate) DeepCopy() *ShardSignTemplate

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardSignTemplate.

func (*ShardSignTemplate) DeepCopyInto

func (in *ShardSignTemplate) DeepCopyInto(out *ShardSignTemplate)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ShardSpec

type ShardSpec struct {
	//Selector            *metav1.LabelSelector `json:"selector,omitempty"`
	Replicas             *int32                  `json:"replicas"`
	DependencyLevel      *int32                  `json:"dependencyLevel"`
	Strategy             *app.DeploymentStrategy `json:"strategy,omitempty"`
	CustomInfo           string                  `json:"customInfo,omitempty"`
	CompressedCustomInfo string                  `json:"compressedCustomInfo,omitempty"`
	Signature            string                  `json:"signature,omitempty"`
	UserDefVersion       string                  `json:"userDefVersion,omitempty"`
	Preload              bool                    `json:"preload,omitempty"`
	// Template describes basic resource template.
	Template            HippoPodTemplate     `json:"template"`
	HealthCheckerConfig *HealthCheckerConfig `json:"healthCheckerConfig"`
	Online              *bool                `json:"online,omitempty"`
	// UpdatingGracefully means is need to unpublish before update
	UpdatingGracefully *bool  `json:"updatingGracefully,omitempty"`
	Cm2TopoInfo        string `json:"cm2TopoInfo,omitempty"`
}

ShardSpec is the spec for shard resource

func (*ShardSpec) DeepCopy

func (in *ShardSpec) DeepCopy() *ShardSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardSpec.

func (*ShardSpec) DeepCopyInto

func (in *ShardSpec) DeepCopyInto(out *ShardSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ShardSpec) GetReplicas

func (s *ShardSpec) GetReplicas() int32

GetReplicas GetReplicas

type ShardTemplate

type ShardTemplate struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              ShardSpec `json:"shardSpec,omitempty"`
}

ShardTemplate is the template of Shard

func (*ShardTemplate) DeepCopy

func (in *ShardTemplate) DeepCopy() *ShardTemplate

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardTemplate.

func (*ShardTemplate) DeepCopyInto

func (in *ShardTemplate) DeepCopyInto(out *ShardTemplate)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Signable

type Signable interface {
	Signature() (rollingSign string, refreshSign string, err error)
}

Signable is used to for rollingSet and deployment to sign

type SignedVersionPlan

type SignedVersionPlan struct {
	// ShardGroupVersion group version
	ShardGroupVersion string `json:"shardGroupVersion,omitempty"`
	// Template describes basic resource template.
	Template *HippoPodTemplate `json:"template"`
	//Signature
	Signature string `json:"signature,omitempty"`
	// RestartAfterResourceChange means is need to restart, after resource change
	RestartAfterResourceChange *bool             `json:"restartAfterResourceChange,omitempty"`
	BufferSelector             map[string]string `json:"bufferSelector,omitempty"`
	Cm2TopoInfo                string            `json:"cm2TopoInfo,omitempty"`
}

SignedVersionPlan SignedVersionPlan

func (*SignedVersionPlan) DeepCopy

func (in *SignedVersionPlan) DeepCopy() *SignedVersionPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SignedVersionPlan.

func (*SignedVersionPlan) DeepCopyInto

func (in *SignedVersionPlan) DeepCopyInto(out *SignedVersionPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*SignedVersionPlan) Descriptor

func (*SignedVersionPlan) Descriptor() ([]byte, []int)

func (*SignedVersionPlan) Marshal

func (m *SignedVersionPlan) Marshal() (dAtA []byte, err error)

func (*SignedVersionPlan) MarshalTo

func (m *SignedVersionPlan) MarshalTo(dAtA []byte) (int, error)

func (*SignedVersionPlan) MarshalToSizedBuffer

func (m *SignedVersionPlan) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*SignedVersionPlan) ProtoMessage

func (*SignedVersionPlan) ProtoMessage()

func (*SignedVersionPlan) Reset

func (m *SignedVersionPlan) Reset()

func (*SignedVersionPlan) Size

func (m *SignedVersionPlan) Size() (n int)

func (*SignedVersionPlan) String

func (this *SignedVersionPlan) String() string

func (*SignedVersionPlan) Unmarshal

func (m *SignedVersionPlan) Unmarshal(dAtA []byte) error

func (*SignedVersionPlan) XXX_DiscardUnknown

func (m *SignedVersionPlan) XXX_DiscardUnknown()

func (*SignedVersionPlan) XXX_Marshal

func (m *SignedVersionPlan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SignedVersionPlan) XXX_Merge

func (m *SignedVersionPlan) XXX_Merge(src proto.Message)

func (*SignedVersionPlan) XXX_Size

func (m *SignedVersionPlan) XXX_Size() int

func (*SignedVersionPlan) XXX_Unmarshal

func (m *SignedVersionPlan) XXX_Unmarshal(b []byte) error

type SkylinePublisherConf

type SkylinePublisherConf struct {
	AppName          string `json:"appName"`
	Host             string `json:"host"`
	Group            string `json:"group"`
	BuffGroup        string `json:"buffGroup"`
	AppUseType       string `json:"appUseType"`
	ReturnAppUseType string `json:"returnAppUseType"`
	Key              string `json:"key"`
	Secret           string `json:"secret"`
}

SkylinePublisherConf is the config of skyline publisher

func (*SkylinePublisherConf) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SkylinePublisherConf.

func (*SkylinePublisherConf) DeepCopyInto

func (in *SkylinePublisherConf) DeepCopyInto(out *SkylinePublisherConf)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SpotStatus

type SpotStatus struct {
	Target    int64    `json:"target,omitempty"`
	Instances []string `json:"instances,omitempty"`
}

func (*SpotStatus) DeepCopy

func (in *SpotStatus) DeepCopy() *SpotStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SpotStatus.

func (*SpotStatus) DeepCopyInto

func (in *SpotStatus) DeepCopyInto(out *SpotStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Spread

type Spread struct {
	Active   SpreadPatch `json:"active"`
	Inactive SpreadPatch `json:"inactive"`
}

func (*Spread) DeepCopy

func (in *Spread) DeepCopy() *Spread

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Spread.

func (*Spread) DeepCopyInto

func (in *Spread) DeepCopyInto(out *Spread)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SpreadPatch

type SpreadPatch struct {
	Replica     int               `json:"replica"`
	Labels      map[string]string `json:"labels,omitempty"`
	Annotations map[string]string `json:"annotations,omitempty"`
}

func (*SpreadPatch) DeepCopy

func (in *SpreadPatch) DeepCopy() *SpreadPatch

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SpreadPatch.

func (*SpreadPatch) DeepCopyInto

func (in *SpreadPatch) DeepCopyInto(out *SpreadPatch)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Subrs

type Subrs struct {
	Name        string            `json:"name"`
	Replica     int32             `json:"replica"`
	Metas       map[string]string `json:"metas"`
	Annotations map[string]string `json:"annotations"`
	Labels      map[string]string `json:"labels"`
}

func (*Subrs) DeepCopy

func (in *Subrs) DeepCopy() *Subrs

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Subrs.

func (*Subrs) DeepCopyInto

func (in *Subrs) DeepCopyInto(out *Subrs)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SubrsMetas

type SubrsMetas map[string]map[string]string

SubrsMetas ...

func (SubrsMetas) DeepCopy

func (in SubrsMetas) DeepCopy() SubrsMetas

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubrsMetas.

func (SubrsMetas) DeepCopyInto

func (in SubrsMetas) DeepCopyInto(out *SubrsMetas)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SubrsVersionStatusMap

type SubrsVersionStatusMap map[string]GroupVersionStatusMap

SubrsVersionStatusMap ...

func (SubrsVersionStatusMap) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubrsVersionStatusMap.

func (SubrsVersionStatusMap) DeepCopyInto

func (in SubrsVersionStatusMap) DeepCopyInto(out *SubrsVersionStatusMap)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TemporaryConstraint

type TemporaryConstraint struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   TemporaryConstraintSpec   `json:"spec"`
	Status TemporaryConstraintStatus `json:"status"`
}

TemporaryConstraint is nodeaffinity with ttl

func (*TemporaryConstraint) DeepCopy

func (in *TemporaryConstraint) DeepCopy() *TemporaryConstraint

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TemporaryConstraint.

func (*TemporaryConstraint) DeepCopyInto

func (in *TemporaryConstraint) DeepCopyInto(out *TemporaryConstraint)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TemporaryConstraint) DeepCopyObject

func (in *TemporaryConstraint) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type TemporaryConstraintList

type TemporaryConstraintList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []TemporaryConstraint `json:"items"`
}

TemporaryConstraintList is a list of WorkerNode resources

func (*TemporaryConstraintList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TemporaryConstraintList.

func (*TemporaryConstraintList) DeepCopyInto

func (in *TemporaryConstraintList) DeepCopyInto(out *TemporaryConstraintList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TemporaryConstraintList) DeepCopyObject

func (in *TemporaryConstraintList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type TemporaryConstraintRule

type TemporaryConstraintRule struct {
	NodeAffinity *corev1.NodeAffinity `json:"nodeAffinity,omitempty"`
	DeadTime     int64                `json:"deadTime,omitempty"`
}

TemporaryConstraintRule TemporaryConstraintRule

func (*TemporaryConstraintRule) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TemporaryConstraintRule.

func (*TemporaryConstraintRule) DeepCopyInto

func (in *TemporaryConstraintRule) DeepCopyInto(out *TemporaryConstraintRule)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TemporaryConstraintSpec

type TemporaryConstraintSpec struct {
	Rule *TemporaryConstraintRule `json:"temporaryConstraintRule,omitempty"`
	APP  string                   `json:"app,omitempty"`
	Role string                   `json:"role,omitempty"`
	IP   string                   `json:"ip,omitempty"`
}

TemporaryConstraintSpec TemporaryConstraintSpec

func (*TemporaryConstraintSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TemporaryConstraintSpec.

func (*TemporaryConstraintSpec) DeepCopyInto

func (in *TemporaryConstraintSpec) DeepCopyInto(out *TemporaryConstraintSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TemporaryConstraintStatus

type TemporaryConstraintStatus struct{}

TemporaryConstraintStatus TemporaryConstraintStatus

func (*TemporaryConstraintStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TemporaryConstraintStatus.

func (*TemporaryConstraintStatus) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Ulimit

type Ulimit struct {
	Name string `json:"Name,omitempty"`
	Soft int    `json:"Soft,omitempty"`
	Hard int    `json:"Hard,omitempty"`
}

Ulimit Ulimit

func (*Ulimit) DeepCopy

func (in *Ulimit) DeepCopy() *Ulimit

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Ulimit.

func (*Ulimit) DeepCopyInto

func (in *Ulimit) DeepCopyInto(out *Ulimit)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Ulimit) Descriptor

func (*Ulimit) Descriptor() ([]byte, []int)

func (*Ulimit) Marshal

func (m *Ulimit) Marshal() (dAtA []byte, err error)

func (*Ulimit) MarshalTo

func (m *Ulimit) MarshalTo(dAtA []byte) (int, error)

func (*Ulimit) MarshalToSizedBuffer

func (m *Ulimit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Ulimit) ProtoMessage

func (*Ulimit) ProtoMessage()

func (*Ulimit) Reset

func (m *Ulimit) Reset()

func (*Ulimit) Size

func (m *Ulimit) Size() (n int)

func (*Ulimit) String

func (this *Ulimit) String() string

func (*Ulimit) Unmarshal

func (m *Ulimit) Unmarshal(dAtA []byte) error

func (*Ulimit) XXX_DiscardUnknown

func (m *Ulimit) XXX_DiscardUnknown()

func (*Ulimit) XXX_Marshal

func (m *Ulimit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Ulimit) XXX_Merge

func (m *Ulimit) XXX_Merge(src proto.Message)

func (*Ulimit) XXX_Size

func (m *Ulimit) XXX_Size() int

func (*Ulimit) XXX_Unmarshal

func (m *Ulimit) XXX_Unmarshal(b []byte) error

type UnassignedReasonType

type UnassignedReasonType int

UnassignedReasonType UnassignedReasonType

const (
	UnassignedReasonNone              UnassignedReasonType = 0
	UnassignedReasonCreatePodErr      UnassignedReasonType = 1
	UnassignedReasonNotSchedule       UnassignedReasonType = 2
	UnassignedReasonQuotaNotEnough    UnassignedReasonType = 3
	UnassignedReasonQuotaNotExist     UnassignedReasonType = 4
	UnassignedReasonResourceNotEnough UnassignedReasonType = 5
)

UnassignedReasons

func GetUnassignedResson

func GetUnassignedResson(pod *corev1.Pod) UnassignedReasonType

GetUnassignedResson GetUnassignedResson

type UpdatePhase

type UpdatePhase int
const (
	PhaseUnknown   UpdatePhase = 0
	PhaseReady     UpdatePhase = 1
	PhaseEvicting  UpdatePhase = 2
	PhaseDeploying UpdatePhase = 3
	PhaseStopping  UpdatePhase = 4
	PhaseFailed    UpdatePhase = 5
	PhaseReclaim   UpdatePhase = 6
)

type UpdateStatus

type UpdateStatus struct {
	TargetVersion string       `json:"targetVersion"`
	CurVersion    string       `json:"curVersion"`
	UpdateAt      int64        `json:"updateAt"`
	Phase         UpdatePhase  `json:"phase"`
	HealthStatus  HealthStatus `json:"healthStatus"`
}

func (*UpdateStatus) DeepCopy

func (in *UpdateStatus) DeepCopy() *UpdateStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new UpdateStatus.

func (*UpdateStatus) DeepCopyInto

func (in *UpdateStatus) DeepCopyInto(out *UpdateStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VersionPlan

type VersionPlan struct {
	SignedVersionPlan
	BroadcastPlan
}

VersionPlan is the spec for a VersionPlan resource

func (*VersionPlan) DeepCopy

func (in *VersionPlan) DeepCopy() *VersionPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VersionPlan.

func (*VersionPlan) DeepCopyInto

func (in *VersionPlan) DeepCopyInto(out *VersionPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*VersionPlan) Descriptor

func (*VersionPlan) Descriptor() ([]byte, []int)

func (*VersionPlan) Marshal

func (m *VersionPlan) Marshal() (dAtA []byte, err error)

func (*VersionPlan) MarshalTo

func (m *VersionPlan) MarshalTo(dAtA []byte) (int, error)

func (*VersionPlan) MarshalToSizedBuffer

func (m *VersionPlan) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*VersionPlan) ProtoMessage

func (*VersionPlan) ProtoMessage()

func (*VersionPlan) Reset

func (m *VersionPlan) Reset()

func (*VersionPlan) Size

func (m *VersionPlan) Size() (n int)

func (*VersionPlan) String

func (this *VersionPlan) String() string

func (*VersionPlan) Unmarshal

func (m *VersionPlan) Unmarshal(dAtA []byte) error

func (*VersionPlan) XXX_DiscardUnknown

func (m *VersionPlan) XXX_DiscardUnknown()

func (*VersionPlan) XXX_Marshal

func (m *VersionPlan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*VersionPlan) XXX_Merge

func (m *VersionPlan) XXX_Merge(src proto.Message)

func (*VersionPlan) XXX_Size

func (m *VersionPlan) XXX_Size() int

func (*VersionPlan) XXX_Unmarshal

func (m *VersionPlan) XXX_Unmarshal(b []byte) error

type VersionPlanWithGangPlan

type VersionPlanWithGangPlan struct {
	*VersionPlan
	GangVersionPlans map[string]*VersionPlan
}

VersionPlanWithGangPlan contains replica versionPlan and gang versionPlan

func GetVersionPlanWithGangPlanFromRS

func GetVersionPlanWithGangPlanFromRS(rollingSet *RollingSet) *VersionPlanWithGangPlan

GetVersionPlanWithGangPlanFromRS returns rollingset VersionPlanWithGangPlan

func GetVersionPlanWithGangPlanFromReplica

func GetVersionPlanWithGangPlanFromReplica(replica *Replica) *VersionPlanWithGangPlan

GetVersionPlanWithGangPlanFromReplica returns replica VersionPlanWithGangPlan

func (*VersionPlanWithGangPlan) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VersionPlanWithGangPlan.

func (*VersionPlanWithGangPlan) DeepCopyInto

func (in *VersionPlanWithGangPlan) DeepCopyInto(out *VersionPlanWithGangPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VpcSlbPublisherConf

type VpcSlbPublisherConf struct {
	SlbApiEndpoint  string `json:"slbApiEndpoint"`
	EcsApiEndpoint  string `json:"ecsApiEndpoint"`
	LoadBalancerId  string `json:"lbId"`            // SLB 实例ID   lb-uf64ua6l5z4h4a2ts7yrr
	VpcId           string `json:"vpcId"`           // VPC 的ID   vpc-uf65qwgtx7npywl2kiwk5
	RegionId        string `json:"regionId"`        // 地域Id cn-shanghai
	VSwitchId       string `json:"vswitchId"`       // 这个参数是用来获取eni的时候,一个过滤条件,非必填
	ResourceGroupId string `json:"resourceGroupId"` // 这个参数同上
	VServerGroupId  string `json:"vServerGroupId"`  // 后端虚拟组ID
	ServicePort     int32  `json:"servicePort"`     // 后端server的端口号
	ListenerPort    int32  `json:"listenerPort"`    // 监听的端口号   这个是checkHealth 那个接口用到的
}

func (*VpcSlbPublisherConf) DeepCopy

func (in *VpcSlbPublisherConf) DeepCopy() *VpcSlbPublisherConf

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VpcSlbPublisherConf.

func (*VpcSlbPublisherConf) DeepCopyInto

func (in *VpcSlbPublisherConf) DeepCopyInto(out *VpcSlbPublisherConf)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type WorkerCondition

type WorkerCondition struct {
	// Type of worker node condition.
	Type WorkerConditionType `json:"type"`
	// Status of the condition, one of True, False, Unknown.
	Status corev1.ConditionStatus `json:"status"`
	// The last time the condition transitioned from one status to another.
	// +optional
	LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"`
	// The reason for the condition's last transition.
	// +optional
	Reason string `json:"reason,omitempty"`
	// A human readable message indicating details about the transition.
	// +optional
	Message string `json:"message,omitempty"`
}

WorkerCondition describes the state of a worker at a certain point.

func (*WorkerCondition) DeepCopy

func (in *WorkerCondition) DeepCopy() *WorkerCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerCondition.

func (*WorkerCondition) DeepCopyInto

func (in *WorkerCondition) DeepCopyInto(out *WorkerCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerCondition) Descriptor

func (*WorkerCondition) Descriptor() ([]byte, []int)

func (*WorkerCondition) Marshal

func (m *WorkerCondition) Marshal() (dAtA []byte, err error)

func (*WorkerCondition) MarshalTo

func (m *WorkerCondition) MarshalTo(dAtA []byte) (int, error)

func (*WorkerCondition) MarshalToSizedBuffer

func (m *WorkerCondition) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerCondition) ProtoMessage

func (*WorkerCondition) ProtoMessage()

func (*WorkerCondition) Reset

func (m *WorkerCondition) Reset()

func (*WorkerCondition) Size

func (m *WorkerCondition) Size() (n int)

func (*WorkerCondition) String

func (this *WorkerCondition) String() string

func (*WorkerCondition) Unmarshal

func (m *WorkerCondition) Unmarshal(dAtA []byte) error

func (*WorkerCondition) XXX_DiscardUnknown

func (m *WorkerCondition) XXX_DiscardUnknown()

func (*WorkerCondition) XXX_Marshal

func (m *WorkerCondition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerCondition) XXX_Merge

func (m *WorkerCondition) XXX_Merge(src proto.Message)

func (*WorkerCondition) XXX_Size

func (m *WorkerCondition) XXX_Size() int

func (*WorkerCondition) XXX_Unmarshal

func (m *WorkerCondition) XXX_Unmarshal(b []byte) error

type WorkerConditionType

type WorkerConditionType string

WorkerConditionType define a worker condition status type

type WorkerModeType

type WorkerModeType string

WorkerModeType WorkerModeType

const (
	WorkerModeTypeActive  WorkerModeType = "active"
	WorkerModeTypeHot     WorkerModeType = "hotStandBy"
	WorkerModeTypeWarm    WorkerModeType = "warmStandBy"
	WorkerModeTypeCold    WorkerModeType = "coldStandBy"
	WorkerModeTypeUnknown WorkerModeType = "unknown"

	WorkerModeTypeInactive WorkerModeType = "inactive"
)

RecycleMode

func GetWorkerCurrentModeType

func GetWorkerCurrentModeType(worker *WorkerNode) WorkerModeType

GetWorkerCurrentModeType GetWorkerCurrentModeType

func GetWorkerTargetModeType

func GetWorkerTargetModeType(worker *WorkerNode) WorkerModeType

GetWorkerTargetModeType GetWorkerTargetModeType

type WorkerNode

type WorkerNode struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   WorkerNodeSpec   `json:"spec"`
	Status WorkerNodeStatus `json:"status"`
}

WorkerNode is a abstraction layer for a base worker container

func (*WorkerNode) Copy4PBPersist

func (w *WorkerNode) Copy4PBPersist() (proto.Message, error)

func (*WorkerNode) DeepCopy

func (in *WorkerNode) DeepCopy() *WorkerNode

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNode.

func (*WorkerNode) DeepCopyInto

func (in *WorkerNode) DeepCopyInto(out *WorkerNode)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerNode) DeepCopyObject

func (in *WorkerNode) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*WorkerNode) Descriptor

func (*WorkerNode) Descriptor() ([]byte, []int)

func (*WorkerNode) GetKind

func (w *WorkerNode) GetKind() string

GetKind get kind of obj

func (*WorkerNode) GetQualifiedName

func (w *WorkerNode) GetQualifiedName() string

GetQualifiedName GetQualifiedName

func (*WorkerNode) Marshal

func (m *WorkerNode) Marshal() (dAtA []byte, err error)

func (*WorkerNode) MarshalTo

func (m *WorkerNode) MarshalTo(dAtA []byte) (int, error)

func (*WorkerNode) MarshalToSizedBuffer

func (m *WorkerNode) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerNode) ProtoMessage

func (*WorkerNode) ProtoMessage()

func (*WorkerNode) Reset

func (m *WorkerNode) Reset()

func (*WorkerNode) Size

func (m *WorkerNode) Size() (n int)

func (*WorkerNode) String

func (w *WorkerNode) String() string

func (*WorkerNode) Unmarshal

func (m *WorkerNode) Unmarshal(dAtA []byte) error

func (*WorkerNode) XXX_DiscardUnknown

func (m *WorkerNode) XXX_DiscardUnknown()

func (*WorkerNode) XXX_Marshal

func (m *WorkerNode) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerNode) XXX_Merge

func (m *WorkerNode) XXX_Merge(src proto.Message)

func (*WorkerNode) XXX_Size

func (m *WorkerNode) XXX_Size() int

func (*WorkerNode) XXX_Unmarshal

func (m *WorkerNode) XXX_Unmarshal(b []byte) error

type WorkerNodeEviction

type WorkerNodeEviction struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   WorkerNodeEvictionSpec   `json:"spec"`
	Status WorkerNodeEvictionStatus `json:"status"`
}

WorkerNodeEviction WorkerNodeEviction

func (*WorkerNodeEviction) DeepCopy

func (in *WorkerNodeEviction) DeepCopy() *WorkerNodeEviction

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeEviction.

func (*WorkerNodeEviction) DeepCopyInto

func (in *WorkerNodeEviction) DeepCopyInto(out *WorkerNodeEviction)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerNodeEviction) DeepCopyObject

func (in *WorkerNodeEviction) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type WorkerNodeEvictionList

type WorkerNodeEvictionList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []WorkerNodeEviction `json:"items"`
}

WorkerNodeEvictionList WorkerNodeEvictionList

func (*WorkerNodeEvictionList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeEvictionList.

func (*WorkerNodeEvictionList) DeepCopyInto

func (in *WorkerNodeEvictionList) DeepCopyInto(out *WorkerNodeEvictionList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerNodeEvictionList) DeepCopyObject

func (in *WorkerNodeEvictionList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type WorkerNodeEvictionSpec

type WorkerNodeEvictionSpec struct {
	AppName     string               `json:"appName"`
	WorkerNodes []*ReclaimWorkerNode `json:"workerNodes,omitempty"`
	Pref        *HippoPrefrence      `json:"preference,omitempty"`
}

WorkerNodeEvictionSpec WorkerNodeEvictionSpec

func (*WorkerNodeEvictionSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeEvictionSpec.

func (*WorkerNodeEvictionSpec) DeepCopyInto

func (in *WorkerNodeEvictionSpec) DeepCopyInto(out *WorkerNodeEvictionSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type WorkerNodeEvictionStatus

type WorkerNodeEvictionStatus struct {
}

WorkerNodeEvictionStatus WorkerNodeEvictionStatus

func (*WorkerNodeEvictionStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeEvictionStatus.

func (*WorkerNodeEvictionStatus) DeepCopyInto

func (in *WorkerNodeEvictionStatus) DeepCopyInto(out *WorkerNodeEvictionStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type WorkerNodeList

type WorkerNodeList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []WorkerNode `json:"items"`
}

WorkerNodeList is a list of WorkerNode resources

func (*WorkerNodeList) DeepCopy

func (in *WorkerNodeList) DeepCopy() *WorkerNodeList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeList.

func (*WorkerNodeList) DeepCopyInto

func (in *WorkerNodeList) DeepCopyInto(out *WorkerNodeList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerNodeList) DeepCopyObject

func (in *WorkerNodeList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*WorkerNodeList) Descriptor

func (*WorkerNodeList) Descriptor() ([]byte, []int)

func (*WorkerNodeList) Marshal

func (m *WorkerNodeList) Marshal() (dAtA []byte, err error)

func (*WorkerNodeList) MarshalTo

func (m *WorkerNodeList) MarshalTo(dAtA []byte) (int, error)

func (*WorkerNodeList) MarshalToSizedBuffer

func (m *WorkerNodeList) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerNodeList) ProtoMessage

func (*WorkerNodeList) ProtoMessage()

func (*WorkerNodeList) Reset

func (m *WorkerNodeList) Reset()

func (*WorkerNodeList) Size

func (m *WorkerNodeList) Size() (n int)

func (*WorkerNodeList) String

func (this *WorkerNodeList) String() string
func (this *WorkerNode) String() string {
	if this == nil {
		return "nil"
	}
	s := strings.Join([]string{`&WorkerNode{`,
		`TypeMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.TypeMeta), "TypeMeta", "v1.TypeMeta", 1), `&`, ``, 1) + `,`,
		`ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`,
		`Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "WorkerNodeSpec", "WorkerNodeSpec", 1), `&`, ``, 1) + `,`,
		`Status:` + strings.Replace(strings.Replace(this.Status.String(), "WorkerNodeStatus", "WorkerNodeStatus", 1), `&`, ``, 1) + `,`,
		`}`,
	}, "")
	return s
}

func (*WorkerNodeList) Unmarshal

func (m *WorkerNodeList) Unmarshal(dAtA []byte) error

func (*WorkerNodeList) XXX_DiscardUnknown

func (m *WorkerNodeList) XXX_DiscardUnknown()

func (*WorkerNodeList) XXX_Marshal

func (m *WorkerNodeList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerNodeList) XXX_Merge

func (m *WorkerNodeList) XXX_Merge(src proto.Message)

func (*WorkerNodeList) XXX_Size

func (m *WorkerNodeList) XXX_Size() int

func (*WorkerNodeList) XXX_Unmarshal

func (m *WorkerNodeList) XXX_Unmarshal(b []byte) error

type WorkerNodeSpec

type WorkerNodeSpec struct {
	// Selector is a label query over pods that should match the replica count.
	// Label keys and values that must match in order to be controlled by this replica set.
	// It must match the pod template's labels.
	// More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors
	Selector *metav1.LabelSelector `json:"selector"`
	// ResoVersion means the signature of Resources.
	ResVersion string `json:"resVersion"`
	// Version means the signature of VersionPlan.
	Version string `json:"version"`
	// config for resource and progress
	VersionPlan `json:",inline"`
	WorkerMode  WorkerModeType `json:"workerMode,omitempty"`
	// DependencyReady 依赖的服务是否ready
	DependencyReady *bool `json:"dependencyReady,omitempty"`
	// Is worker to delete.
	ToDelete bool `json:"toDelete"`

	// Is worker releasing .Different from ToDelete field, may be delete pod and create a new one.
	Releasing bool `json:"releasing"`
	// Is worker reclaim
	Reclaim bool `json:"reclaim"`

	OwnerGeneration int64 `json:"ownerGeneration,omitempty"`

	// specific the resource pool, enum Fixed Cyclical
	ResourcePool string `json:"resourcePool,omitempty"`
	DeletionCost int64  `json:"deletionCost,omitempty"`
	StandbyHours string `json:"standbyHours,omitempty"`

	BackupOfPod BackupOfPod `json:"backupOfPod,omitempty"`

	IsSpot bool `json:"isSpot,omitempty"`
}

WorkerNodeSpec is a spec layer for a base workernode resource

func (*WorkerNodeSpec) DeepCopy

func (in *WorkerNodeSpec) DeepCopy() *WorkerNodeSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeSpec.

func (*WorkerNodeSpec) DeepCopyInto

func (in *WorkerNodeSpec) DeepCopyInto(out *WorkerNodeSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerNodeSpec) Descriptor

func (*WorkerNodeSpec) Descriptor() ([]byte, []int)

func (*WorkerNodeSpec) Marshal

func (m *WorkerNodeSpec) Marshal() (dAtA []byte, err error)

func (*WorkerNodeSpec) MarshalTo

func (m *WorkerNodeSpec) MarshalTo(dAtA []byte) (int, error)

func (*WorkerNodeSpec) MarshalToSizedBuffer

func (m *WorkerNodeSpec) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerNodeSpec) ProtoMessage

func (*WorkerNodeSpec) ProtoMessage()

func (*WorkerNodeSpec) Reset

func (m *WorkerNodeSpec) Reset()

func (*WorkerNodeSpec) Size

func (m *WorkerNodeSpec) Size() (n int)

func (*WorkerNodeSpec) String

func (this *WorkerNodeSpec) String() string

func (*WorkerNodeSpec) Unmarshal

func (m *WorkerNodeSpec) Unmarshal(dAtA []byte) error

func (*WorkerNodeSpec) XXX_DiscardUnknown

func (m *WorkerNodeSpec) XXX_DiscardUnknown()

func (*WorkerNodeSpec) XXX_Marshal

func (m *WorkerNodeSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerNodeSpec) XXX_Merge

func (m *WorkerNodeSpec) XXX_Merge(src proto.Message)

func (*WorkerNodeSpec) XXX_Size

func (m *WorkerNodeSpec) XXX_Size() int

func (*WorkerNodeSpec) XXX_Unmarshal

func (m *WorkerNodeSpec) XXX_Unmarshal(b []byte) error

type WorkerNodeStatus

type WorkerNodeStatus struct {
	AllocatorSyncedStatus `json:",inline"`

	// Notify publisher if it is needed to publish
	ServiceOffline bool `json:"serviceOffline"`
	Warmup         bool `json:"warmup"`
	InWarmup       bool `json:"inWarmup,omitempty"`
	NeedWarmup     bool `json:"needWarmup"`
	InUpdating     bool `json:"inUpdating"`
	InRestarting   bool `json:"inRestarting"`

	// WorkerReady describes if the running process is the health in plan.
	WorkerReady bool `json:"workerReady"`

	// ResourceMatchTimeout describe the last time process not match
	// +optional
	LastWorkerNotReadytime int64 `json:"lastWorkerNotReadytime,omitempty"`

	// Scores calculated by various indicators, for sort and decide which to release(choose the worst state) .
	Score int64 `json:"score"`

	// The phase of a Worker is a simple, high-level summary of where the Worker is in its lifecycle.
	AllocStatus AllocStatus `json:"allocStatus"`

	// The HealthStatus of a Worker is a simple, high-level summary of the health state of worker.
	HealthStatus HealthStatus `json:"healthStatus"`

	// ProcessStep describe the process step of replica controller
	ProcessStep ProcessStep `json:"processStep"`

	// HealthCondition, require to persist in memekube, see issue #96779
	// +optional
	HealthCondition HealthCondition `json:"healthCondition,omitempty"`

	// The HealthStatus of a Worker is a simple, high-level summary of the service state of worker.
	ServiceStatus ServiceStatus `json:"serviceStatus"`

	// list of ServiceConditions
	// +optional
	// +patchMergeKey=type
	// +patchStrategy=merge
	ServiceConditions      []ServiceCondition `json:"serviceConditions,omitempty"`
	ServiceReady           bool               `json:"serviceReady,omitempty"`
	ServiceReadyForMinTime bool               `json:"serviceReadyForMinTime,omitempty"`

	// ServiceInfoMetas  service meta信息 存储cm2信息
	ServiceInfoMetas string `json:"serviceInfoMetas,omitempty" until:"1.0.0"`
	// The conditions array, the reason and message fields contain more detail about the worker's status.
	// list of Conditions
	// +optional
	// +patchMergeKey=type
	// +patchStrategy=merge
	Conditions []WorkerCondition `json:"conditions,omitempty"`

	Complete bool `json:"complete"`

	// Is worker releasing .Different from ToDelete field, may be delete pod and create a new one.
	ToRelease bool `json:"toRelease"`
	//LastUpdateStatusTime 最近一次更新时间
	BadReason BadReasonType `json:"badReason,omitempty"`
	SlotID    HippoSlotID   `json:"slotId,omitempty"`

	WorkerStateChangeRecoder `json:",inline"`

	// PodStandbyStatus standby 顺序信息 //DEPRECATED
	PodStandbyStatus PodStandbyStatus `json:"podStandbyStatus,omitempty"`

	// ServiceInfoMetas不持久化,看是否重启后load到了新值
	ServiceInfoMetasRecoverd bool `json:"serviceInfoMetasRecoverd,omitempty" until:"1.0.0"`
	// PodReady pod conditions type = Ready and status = True
	PodReady bool `json:"podReady"`
	// Id workerNodeId
	Name             string            `json:"name"`
	BadReasonMessage string            `json:"badReasonMessage,omitempty"`
	RestartRecords   map[string]string `json:"restartRecords,omitempty"`

	// isFedWorker
	IsFedWorker bool `json:"isFedWorker"`
}

WorkerNodeStatus is a status for a base workernode resource

func (*WorkerNodeStatus) DeepCopy

func (in *WorkerNodeStatus) DeepCopy() *WorkerNodeStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeStatus.

func (*WorkerNodeStatus) DeepCopyInto

func (in *WorkerNodeStatus) DeepCopyInto(out *WorkerNodeStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerNodeStatus) Descriptor

func (*WorkerNodeStatus) Descriptor() ([]byte, []int)

func (*WorkerNodeStatus) Marshal

func (m *WorkerNodeStatus) Marshal() (dAtA []byte, err error)

func (*WorkerNodeStatus) MarshalTo

func (m *WorkerNodeStatus) MarshalTo(dAtA []byte) (int, error)

func (*WorkerNodeStatus) MarshalToSizedBuffer

func (m *WorkerNodeStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerNodeStatus) ProtoMessage

func (*WorkerNodeStatus) ProtoMessage()

func (*WorkerNodeStatus) Reset

func (m *WorkerNodeStatus) Reset()

func (*WorkerNodeStatus) Size

func (m *WorkerNodeStatus) Size() (n int)

func (*WorkerNodeStatus) String

func (this *WorkerNodeStatus) String() string

func (*WorkerNodeStatus) Unmarshal

func (m *WorkerNodeStatus) Unmarshal(dAtA []byte) error

func (*WorkerNodeStatus) XXX_DiscardUnknown

func (m *WorkerNodeStatus) XXX_DiscardUnknown()

func (*WorkerNodeStatus) XXX_Marshal

func (m *WorkerNodeStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerNodeStatus) XXX_Merge

func (m *WorkerNodeStatus) XXX_Merge(src proto.Message)

func (*WorkerNodeStatus) XXX_Size

func (m *WorkerNodeStatus) XXX_Size() int

func (*WorkerNodeStatus) XXX_Unmarshal

func (m *WorkerNodeStatus) XXX_Unmarshal(b []byte) error

type WorkerNodeTemplate

type WorkerNodeTemplate struct {
	Immutable         bool `json:"immutable"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              WorkerNodeSpec `json:"spec"`
}

func (*WorkerNodeTemplate) DeepCopy

func (in *WorkerNodeTemplate) DeepCopy() *WorkerNodeTemplate

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerNodeTemplate.

func (*WorkerNodeTemplate) DeepCopyInto

func (in *WorkerNodeTemplate) DeepCopyInto(out *WorkerNodeTemplate)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type WorkerPhase

type WorkerPhase string

WorkerPhase is a label for the condition of a worker at the current time.

const (
	// Pending means the worker has been accepted by the system, but one or more of the process
	// has not been started.
	Pending WorkerPhase = "Pending"
	// Running means that all process in the worker have been started ok.
	Running WorkerPhase = "Running"
	// Terminated means that worker have voluntarily terminated.
	Terminated WorkerPhase = "Terminated"
	// Failed means that all process in the worker terminated and at least one process has
	// terminated in a failure (exited with a non-zero exit code or was stopped by the system).
	Failed WorkerPhase = "Failed"
	// Unknown means that for some reason the state of the worker could not be obtained.
	Unknown WorkerPhase = "Unknown"
)

func TransPodPhase

func TransPodPhase(pod *corev1.Pod, processMatch bool) WorkerPhase

TransPodPhase trans pod phase to worker phase

type WorkerSchedulePlan

type WorkerSchedulePlan struct {
	// Minimum number of seconds for which a newly created pod should be ready
	// +optional
	MinReadySeconds int32 `json:"minReadySeconds,omitempty"`

	// WarmupSeconds number of seconds for which a pod need warmup seconds
	// +optional
	WarmupSeconds int32 `json:"warmupSeconds,omitempty"`

	// ResourceMatchTimeout describe the max time for resize resource
	// +optional
	ResourceMatchTimeout int64 `json:"resourceMatchTimeout,omitempty"`
	// ProcessMatchTimeout describe the max time for process match
	// +optional
	ProcessMatchTimeout int64 `json:"processMatchTimeout,omitempty"`
	// ResourceMatchTimeout describe the max time for start new process
	// +optional
	WorkerReadyTimeout int64 `json:"workerReadyTimeout,omitempty"`

	// the maximum of creation of workers for recovery for a period of time
	BrokenRecoverQuotaConfig *BrokenRecoverQuotaConfig `json:"brokenRecoverQuotaConfig"`

	// relaiming strategy of workers
	RecoverStrategy RecoverStrategy `json:"recoverStrategy"`

	// Seconds to delay delete backup workernode
	// +optional
	DelayDeleteBackupSeconds int64 `json:"delayDeleteBackupSeconds,omitempty"`
}

WorkerSchedulePlan define worker ready and qouta and other fields for worker schedule

func (*WorkerSchedulePlan) DeepCopy

func (in *WorkerSchedulePlan) DeepCopy() *WorkerSchedulePlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerSchedulePlan.

func (*WorkerSchedulePlan) DeepCopyInto

func (in *WorkerSchedulePlan) DeepCopyInto(out *WorkerSchedulePlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerSchedulePlan) Descriptor

func (*WorkerSchedulePlan) Descriptor() ([]byte, []int)

func (*WorkerSchedulePlan) Marshal

func (m *WorkerSchedulePlan) Marshal() (dAtA []byte, err error)

func (*WorkerSchedulePlan) MarshalTo

func (m *WorkerSchedulePlan) MarshalTo(dAtA []byte) (int, error)

func (*WorkerSchedulePlan) MarshalToSizedBuffer

func (m *WorkerSchedulePlan) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerSchedulePlan) ProtoMessage

func (*WorkerSchedulePlan) ProtoMessage()

func (*WorkerSchedulePlan) Reset

func (m *WorkerSchedulePlan) Reset()

func (*WorkerSchedulePlan) Size

func (m *WorkerSchedulePlan) Size() (n int)

func (*WorkerSchedulePlan) String

func (this *WorkerSchedulePlan) String() string

func (*WorkerSchedulePlan) Unmarshal

func (m *WorkerSchedulePlan) Unmarshal(dAtA []byte) error

func (*WorkerSchedulePlan) XXX_DiscardUnknown

func (m *WorkerSchedulePlan) XXX_DiscardUnknown()

func (*WorkerSchedulePlan) XXX_Marshal

func (m *WorkerSchedulePlan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerSchedulePlan) XXX_Merge

func (m *WorkerSchedulePlan) XXX_Merge(src proto.Message)

func (*WorkerSchedulePlan) XXX_Size

func (m *WorkerSchedulePlan) XXX_Size() int

func (*WorkerSchedulePlan) XXX_Unmarshal

func (m *WorkerSchedulePlan) XXX_Unmarshal(b []byte) error

type WorkerStateChangeRecoder

type WorkerStateChangeRecoder struct {
	LastServiceReadyTime *int64      `json:"lastServiceReadyTime,omitempty"`
	LastUpdateStatusTime metav1.Time `json:"lastUpdateStatusTime,omitempty" until:"1.0.0"`
	BecomeCurrentTime    metav1.Time `json:"becomeCurrentTime,omitempty"`
	LastDeleteBackupTime int64       `json:"backupDelayDeleteTime,omitempty"`
	AssignedTime         int64       `json:"assignedTime,omitempty"`
	PodReadyTime         int64       `json:"podReadyTime,omitempty"`
	WorkerReadyTime      int64       `json:"lastWorkerReadyTime,omitempty"`
	LastWarmupStartTime  int64       `json:"lastWarmupStartTime,omitempty"`
	LastWarmupEndTime    int64       `json:"lastWarmupEndTime,omitempty"`
}

WorkerStateChangeRecoder WorkerStateChangeRecoder

func (*WorkerStateChangeRecoder) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerStateChangeRecoder.

func (*WorkerStateChangeRecoder) DeepCopyInto

func (in *WorkerStateChangeRecoder) DeepCopyInto(out *WorkerStateChangeRecoder)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerStateChangeRecoder) Descriptor

func (*WorkerStateChangeRecoder) Descriptor() ([]byte, []int)

func (*WorkerStateChangeRecoder) Marshal

func (m *WorkerStateChangeRecoder) Marshal() (dAtA []byte, err error)

func (*WorkerStateChangeRecoder) MarshalTo

func (m *WorkerStateChangeRecoder) MarshalTo(dAtA []byte) (int, error)

func (*WorkerStateChangeRecoder) MarshalToSizedBuffer

func (m *WorkerStateChangeRecoder) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WorkerStateChangeRecoder) ProtoMessage

func (*WorkerStateChangeRecoder) ProtoMessage()

func (*WorkerStateChangeRecoder) Reset

func (m *WorkerStateChangeRecoder) Reset()

func (*WorkerStateChangeRecoder) Size

func (m *WorkerStateChangeRecoder) Size() (n int)

func (*WorkerStateChangeRecoder) String

func (this *WorkerStateChangeRecoder) String() string

func (*WorkerStateChangeRecoder) Unmarshal

func (m *WorkerStateChangeRecoder) Unmarshal(dAtA []byte) error

func (*WorkerStateChangeRecoder) XXX_DiscardUnknown

func (m *WorkerStateChangeRecoder) XXX_DiscardUnknown()

func (*WorkerStateChangeRecoder) XXX_Marshal

func (m *WorkerStateChangeRecoder) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WorkerStateChangeRecoder) XXX_Merge

func (m *WorkerStateChangeRecoder) XXX_Merge(src proto.Message)

func (*WorkerStateChangeRecoder) XXX_Size

func (m *WorkerStateChangeRecoder) XXX_Size() int

func (*WorkerStateChangeRecoder) XXX_Unmarshal

func (m *WorkerStateChangeRecoder) XXX_Unmarshal(b []byte) error

type WorkerType

type WorkerType string

WorkerType define a worker status type

const (
	WorkerTypeUnknow   WorkerType = "WT_UNKNOW"
	WorkerTypeNotReady WorkerType = "WT_NOT_READY"
	WorkerTypeReady    WorkerType = "WT_READY"
)

These are the valid statuses of worker health.

Jump to

Keyboard shortcuts

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