v1alpha1

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: Apache-2.0 Imports: 9 Imported by: 2

Documentation

Overview

+k8s:openapi-gen=true +groupName=game.kruise.io

Package v1alpha1 contains API Schema definitions for the game.kruise.io v1alpha1 API group +kubebuilder:object:generate=true +groupName=game.kruise.io

Index

Constants

View Source
const (
	GameServerStateKey           = "game.kruise.io/gs-state"
	GameServerOpsStateKey        = "game.kruise.io/gs-opsState"
	GameServerUpdatePriorityKey  = "game.kruise.io/gs-update-priority"
	GameServerDeletePriorityKey  = "game.kruise.io/gs-delete-priority"
	GameServerDeletingKey        = "game.kruise.io/gs-deleting"
	GameServerNetworkType        = "game.kruise.io/network-type"
	GameServerNetworkConf        = "game.kruise.io/network-conf"
	GameServerNetworkDisabled    = "game.kruise.io/network-disabled"
	GameServerNetworkStatus      = "game.kruise.io/network-status"
	GameServerNetworkTriggerTime = "game.kruise.io/network-trigger-time"
)
View Source
const (
	GameServerOwnerGssKey      = "game.kruise.io/owner-gss"
	GameServerSetReserveIdsKey = "game.kruise.io/reserve-ids"
	AstsHashKey                = "game.kruise.io/asts-hash"
	PpmHashKey                 = "game.kruise.io/ppm-hash"
	GsTemplateMetadataHashKey  = "game.kruise.io/gsTemplate-metadata-hash"
)
View Source
const (
	AllowNotReadyContainersNetworkConfName = "AllowNotReadyContainers"
)
View Source
const (
	InplaceUpdateNotReadyBlocker = "game.kruise.io/inplace-update-not-ready-blocker"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "game.kruise.io", Version: "v1alpha1"}

	SchemeGroupVersion = GroupVersion

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

func Resource

func Resource(resource string) schema.GroupResource

Resource is required by pkg/client/listers/...

Types

type GameServer

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

	Spec   GameServerSpec   `json:"spec,omitempty"`
	Status GameServerStatus `json:"status,omitempty"`
}

GameServer is the Schema for the gameservers API

func (*GameServer) DeepCopy

func (in *GameServer) DeepCopy() *GameServer

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

func (*GameServer) DeepCopyInto

func (in *GameServer) DeepCopyInto(out *GameServer)

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

func (*GameServer) DeepCopyObject

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

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

type GameServerCondition added in v0.6.0

type GameServerCondition struct {
	// Type is the type of the condition.
	Type GameServerConditionType `json:"type"`
	// Status is the status of the condition.
	// Can be True, False, Unknown.
	Status corev1.ConditionStatus `json:"status"`
	// Last time we probed the condition.
	// +optional
	LastProbeTime metav1.Time `json:"lastProbeTime,omitempty"`
	// Last time the condition transitioned from one status to another.
	// +optional
	LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"`
	// Unique, one-word, CamelCase reason for the condition's last transition.
	// +optional
	Reason string `json:"reason,omitempty"`
	// Human-readable message indicating details about last transition.
	// +optional
	Message string `json:"message,omitempty"`
}

func (*GameServerCondition) DeepCopy added in v0.6.0

func (in *GameServerCondition) DeepCopy() *GameServerCondition

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

func (*GameServerCondition) DeepCopyInto added in v0.6.0

func (in *GameServerCondition) DeepCopyInto(out *GameServerCondition)

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

type GameServerConditionType added in v0.6.0

type GameServerConditionType string
const (
	NodeNormal             GameServerConditionType = "NodeNormal"
	PersistentVolumeNormal GameServerConditionType = "PersistentVolumeNormal"
	PodNormal              GameServerConditionType = "PodNormal"
)

type GameServerContainer added in v0.7.0

type GameServerContainer struct {
	// Name indicates the name of the container to update.
	Name string `json:"name"`
	// Image indicates the image of the container to update.
	// When Image updated, pod.spec.containers[*].image will be updated immediately.
	Image string `json:"image,omitempty"`
	// Resources indicates the resources of the container to update.
	// When Resources updated, pod.spec.containers[*].Resources will be not updated immediately,
	// which will be updated when pod recreate.
	Resources corev1.ResourceRequirements `json:"resources,omitempty"`
}

func (*GameServerContainer) DeepCopy added in v0.7.0

func (in *GameServerContainer) DeepCopy() *GameServerContainer

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

func (*GameServerContainer) DeepCopyInto added in v0.7.0

func (in *GameServerContainer) DeepCopyInto(out *GameServerContainer)

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

type GameServerList

type GameServerList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []GameServer `json:"items"`
}

GameServerList contains a list of GameServer

func (*GameServerList) DeepCopy

func (in *GameServerList) DeepCopy() *GameServerList

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

func (*GameServerList) DeepCopyInto

func (in *GameServerList) DeepCopyInto(out *GameServerList)

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

func (*GameServerList) DeepCopyObject

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

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

type GameServerReclaimPolicy added in v0.7.0

type GameServerReclaimPolicy string
const (
	// CascadeGameServerReclaimPolicy indicates that GameServer is deleted when the pod is deleted.
	// The age of GameServer is exactly the same as that of the pod.
	CascadeGameServerReclaimPolicy GameServerReclaimPolicy = "Cascade"
	// DeleteGameServerReclaimPolicy indicates that GameServers will be deleted when replicas of GameServerSet decreases.
	// The GameServer will not be deleted when the corresponding pod is deleted due to manual deletion, update, eviction, etc.
	DeleteGameServerReclaimPolicy GameServerReclaimPolicy = "Delete"
)

type GameServerSet

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

	Spec   GameServerSetSpec   `json:"spec,omitempty"`
	Status GameServerSetStatus `json:"status,omitempty"`
}

GameServerSet is the Schema for the gameserversets API

func (*GameServerSet) DeepCopy

func (in *GameServerSet) DeepCopy() *GameServerSet

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

func (*GameServerSet) DeepCopyInto

func (in *GameServerSet) DeepCopyInto(out *GameServerSet)

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

func (*GameServerSet) DeepCopyObject

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

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

type GameServerSetList

type GameServerSetList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []GameServerSet `json:"items"`
}

GameServerSetList contains a list of GameServerSet

func (*GameServerSetList) DeepCopy

func (in *GameServerSetList) DeepCopy() *GameServerSetList

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

func (*GameServerSetList) DeepCopyInto

func (in *GameServerSetList) DeepCopyInto(out *GameServerSetList)

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

func (*GameServerSetList) DeepCopyObject

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

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

type GameServerSetSpec

type GameServerSetSpec struct {
	// replicas is the desired number of replicas of the given Template.
	// These are replicas in the sense that they are instantiations of the
	// same Template, but individual replicas also have a consistent identity.
	//+kubebuilder:validation:Required
	//+kubebuilder:validation:Minimum=0
	Replicas *int32 `json:"replicas"`
	// INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	GameServerTemplate   GameServerTemplate `json:"gameServerTemplate,omitempty"`
	ServiceName          string             `json:"serviceName,omitempty"`
	ReserveGameServerIds []int              `json:"reserveGameServerIds,omitempty"`
	ServiceQualities     []ServiceQuality   `json:"serviceQualities,omitempty"`
	UpdateStrategy       UpdateStrategy     `json:"updateStrategy,omitempty"`
	ScaleStrategy        ScaleStrategy      `json:"scaleStrategy,omitempty"`
	Network              *Network           `json:"network,omitempty"`
}

GameServerSetSpec defines the desired state of GameServerSet

func (*GameServerSetSpec) DeepCopy

func (in *GameServerSetSpec) DeepCopy() *GameServerSetSpec

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

func (*GameServerSetSpec) DeepCopyInto

func (in *GameServerSetSpec) DeepCopyInto(out *GameServerSetSpec)

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

type GameServerSetStatus

type GameServerSetStatus struct {
	// The generation observed by the controller.
	// +optional
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`
	// replicas from advancedStatefulSet
	Replicas                int32  `json:"replicas"`
	ReadyReplicas           int32  `json:"readyReplicas"`
	AvailableReplicas       int32  `json:"availableReplicas"`
	CurrentReplicas         int32  `json:"currentReplicas"`
	UpdatedReplicas         int32  `json:"updatedReplicas"`
	UpdatedReadyReplicas    int32  `json:"updatedReadyReplicas,omitempty"`
	MaintainingReplicas     *int32 `json:"maintainingReplicas,omitempty"`
	WaitToBeDeletedReplicas *int32 `json:"waitToBeDeletedReplicas,omitempty"`
	// LabelSelector is label selectors for query over pods that should match the replica count used by HPA.
	LabelSelector string `json:"labelSelector,omitempty"`
}

GameServerSetStatus defines the observed state of GameServerSet

func (*GameServerSetStatus) DeepCopy

func (in *GameServerSetStatus) DeepCopy() *GameServerSetStatus

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

func (*GameServerSetStatus) DeepCopyInto

func (in *GameServerSetStatus) DeepCopyInto(out *GameServerSetStatus)

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

type GameServerSpec

type GameServerSpec struct {
	OpsState         OpsState            `json:"opsState,omitempty"`
	UpdatePriority   *intstr.IntOrString `json:"updatePriority,omitempty"`
	DeletionPriority *intstr.IntOrString `json:"deletionPriority,omitempty"`
	NetworkDisabled  bool                `json:"networkDisabled,omitempty"`
	// Containers can be used to make the corresponding GameServer container fields
	// different from the fields defined by GameServerTemplate in GameServerSetSpec.
	Containers []GameServerContainer `json:"containers,omitempty"`
}

GameServerSpec defines the desired state of GameServer

func (*GameServerSpec) DeepCopy

func (in *GameServerSpec) DeepCopy() *GameServerSpec

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

func (*GameServerSpec) DeepCopyInto

func (in *GameServerSpec) DeepCopyInto(out *GameServerSpec)

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

type GameServerState

type GameServerState string
const (
	Unknown  GameServerState = "Unknown"
	Creating GameServerState = "Creating"
	Ready    GameServerState = "Ready"
	NotReady GameServerState = "NotReady"
	Crash    GameServerState = "Crash"
	Updating GameServerState = "Updating"
	Deleting GameServerState = "Deleting"
)

type GameServerStatus

type GameServerStatus struct {
	// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	DesiredState              GameServerState           `json:"desiredState,omitempty"`
	CurrentState              GameServerState           `json:"currentState,omitempty"`
	NetworkStatus             NetworkStatus             `json:"networkStatus,omitempty"`
	PodStatus                 corev1.PodStatus          `json:"podStatus,omitempty"`
	ServiceQualitiesCondition []ServiceQualityCondition `json:"serviceQualitiesConditions,omitempty"`
	// Lifecycle defines the lifecycle hooks for Pods pre-delete, in-place update.
	UpdatePriority     *intstr.IntOrString `json:"updatePriority,omitempty"`
	DeletionPriority   *intstr.IntOrString `json:"deletionPriority,omitempty"`
	LastTransitionTime metav1.Time         `json:"lastTransitionTime,omitempty"`
	// Conditions is an array of current observed GameServer conditions.
	// +optional
	Conditions []GameServerCondition `json:"conditions,omitempty" `
}

GameServerStatus defines the observed state of GameServer

func (*GameServerStatus) DeepCopy

func (in *GameServerStatus) DeepCopy() *GameServerStatus

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

func (*GameServerStatus) DeepCopyInto

func (in *GameServerStatus) DeepCopyInto(out *GameServerStatus)

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

type GameServerTemplate

type GameServerTemplate struct {
	// +kubebuilder:pruning:PreserveUnknownFields
	// +kubebuilder:validation:Schemaless
	corev1.PodTemplateSpec `json:",inline"`
	VolumeClaimTemplates   []corev1.PersistentVolumeClaim `json:"volumeClaimTemplates,omitempty"`
	// ReclaimPolicy indicates the reclaim policy for GameServer.
	// Default is Cascade.
	ReclaimPolicy GameServerReclaimPolicy `json:"reclaimPolicy,omitempty"`
}

func (*GameServerTemplate) DeepCopy

func (in *GameServerTemplate) DeepCopy() *GameServerTemplate

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

func (*GameServerTemplate) DeepCopyInto

func (in *GameServerTemplate) DeepCopyInto(out *GameServerTemplate)

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

type KVParams

type KVParams struct {
	Name  string `json:"name,omitempty"`
	Value string `json:"value,omitempty"`
}

func (*KVParams) DeepCopy

func (in *KVParams) DeepCopy() *KVParams

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

func (*KVParams) DeepCopyInto

func (in *KVParams) DeepCopyInto(out *KVParams)

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

type Network

type Network struct {
	NetworkType string              `json:"networkType,omitempty"`
	NetworkConf []NetworkConfParams `json:"networkConf,omitempty"`
}

func (*Network) DeepCopy

func (in *Network) DeepCopy() *Network

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

func (*Network) DeepCopyInto

func (in *Network) DeepCopyInto(out *Network)

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

type NetworkAddress

type NetworkAddress struct {
	IP string `json:"ip"`
	// TODO add IPv6
	Ports     []NetworkPort     `json:"ports,omitempty"`
	PortRange *NetworkPortRange `json:"portRange,omitempty"`
	EndPoint  string            `json:"endPoint,omitempty"`
}

func (*NetworkAddress) DeepCopy

func (in *NetworkAddress) DeepCopy() *NetworkAddress

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

func (*NetworkAddress) DeepCopyInto

func (in *NetworkAddress) DeepCopyInto(out *NetworkAddress)

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

type NetworkConfParams

type NetworkConfParams KVParams

func (*NetworkConfParams) DeepCopy

func (in *NetworkConfParams) DeepCopy() *NetworkConfParams

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

func (*NetworkConfParams) DeepCopyInto

func (in *NetworkConfParams) DeepCopyInto(out *NetworkConfParams)

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

type NetworkPort

type NetworkPort struct {
	Name     string              `json:"name"`
	Protocol corev1.Protocol     `json:"protocol,omitempty"`
	Port     *intstr.IntOrString `json:"port,omitempty"`
}

func (*NetworkPort) DeepCopy

func (in *NetworkPort) DeepCopy() *NetworkPort

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

func (*NetworkPort) DeepCopyInto

func (in *NetworkPort) DeepCopyInto(out *NetworkPort)

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

type NetworkPortRange

type NetworkPortRange struct {
	Protocol  corev1.Protocol `json:"protocol,omitempty"`
	PortRange string          `json:"portRange,omitempty"`
}

func (*NetworkPortRange) DeepCopy

func (in *NetworkPortRange) DeepCopy() *NetworkPortRange

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

func (*NetworkPortRange) DeepCopyInto

func (in *NetworkPortRange) DeepCopyInto(out *NetworkPortRange)

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

type NetworkState

type NetworkState string
const (
	NetworkReady    NetworkState = "Ready"
	NetworkWaiting  NetworkState = "Waiting"
	NetworkNotReady NetworkState = "NotReady"
)

type NetworkStatus

type NetworkStatus struct {
	NetworkType         string           `json:"networkType,omitempty"`
	InternalAddresses   []NetworkAddress `json:"internalAddresses,omitempty"`
	ExternalAddresses   []NetworkAddress `json:"externalAddresses,omitempty"`
	DesiredNetworkState NetworkState     `json:"desiredNetworkState,omitempty"`
	CurrentNetworkState NetworkState     `json:"currentNetworkState,omitempty"`
	CreateTime          metav1.Time      `json:"createTime,omitempty"`
	LastTransitionTime  metav1.Time      `json:"lastTransitionTime,omitempty"`
}

func (*NetworkStatus) DeepCopy

func (in *NetworkStatus) DeepCopy() *NetworkStatus

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

func (*NetworkStatus) DeepCopyInto

func (in *NetworkStatus) DeepCopyInto(out *NetworkStatus)

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

type OpsState

type OpsState string
const (
	Maintaining  OpsState = "Maintaining"
	WaitToDelete OpsState = "WaitToBeDeleted"
	None         OpsState = "None"
	Allocated    OpsState = "Allocated"
	Kill         OpsState = "Kill"
)

type RollingUpdateStatefulSetStrategy

type RollingUpdateStatefulSetStrategy struct {
	// Partition indicates the ordinal at which the StatefulSet should be partitioned by default.
	// But if unorderedUpdate has been set:
	//   - Partition indicates the number of pods with non-updated revisions when rolling update.
	//   - It means controller will update $(replicas - partition) number of pod.
	// Default value is 0.
	// +optional
	Partition *int32 `json:"partition,omitempty"`
	// The maximum number of pods that can be unavailable during the update.
	// Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%).
	// Absolute number is calculated from percentage by rounding down.
	// Also, maxUnavailable can just be allowed to work with Parallel podManagementPolicy.
	// Defaults to 1.
	// +optional
	MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty"`
	// PodUpdatePolicy indicates how pods should be updated
	// Default value is "ReCreate"
	// +optional
	PodUpdatePolicy kruiseV1beta1.PodUpdateStrategyType `json:"podUpdatePolicy,omitempty"`
	// Paused indicates that the StatefulSet is paused.
	// Default value is false
	// +optional
	Paused bool `json:"paused,omitempty"`
	// UnorderedUpdate contains strategies for non-ordered update.
	// If it is not nil, pods will be updated with non-ordered sequence.
	// Noted that UnorderedUpdate can only be allowed to work with Parallel podManagementPolicy
	// +optional
	// UnorderedUpdate *kruiseV1beta1.UnorderedUpdateStrategy `json:"unorderedUpdate,omitempty"`
	// InPlaceUpdateStrategy contains strategies for in-place update.
	// +optional
	InPlaceUpdateStrategy *appspub.InPlaceUpdateStrategy `json:"inPlaceUpdateStrategy,omitempty"`
	// MinReadySeconds indicates how long will the pod be considered ready after it's updated.
	// MinReadySeconds works with both OrderedReady and Parallel podManagementPolicy.
	// It affects the pod scale up speed when the podManagementPolicy is set to be OrderedReady.
	// Combined with MaxUnavailable, it affects the pod update speed regardless of podManagementPolicy.
	// Default value is 0, max is 300.
	// +optional
	MinReadySeconds *int32 `json:"minReadySeconds,omitempty"`
}

func (*RollingUpdateStatefulSetStrategy) DeepCopy

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

func (*RollingUpdateStatefulSetStrategy) DeepCopyInto

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

type ScaleDownStrategyType added in v0.3.0

type ScaleDownStrategyType string

ScaleDownStrategyType is a string enumeration type that enumerates all possible scale down strategies for the GameServerSet controller. +enum

const (
	// GeneralScaleDownStrategyType will first consider the ReserveGameServerIds
	// field when game server scaling down. When the number of reserved game servers
	// does not meet the scale down number, continue to select and delete the game
	// servers from the current game server list.
	GeneralScaleDownStrategyType ScaleDownStrategyType = "General"
	// ReserveIdsScaleDownStrategyType will backfill the sequence numbers into
	// ReserveGameServerIds field when GameServers scale down, whether set by
	// ReserveGameServerIds field or the GameServerSet controller chooses to remove it.
	ReserveIdsScaleDownStrategyType ScaleDownStrategyType = "ReserveIds"
)

type ScaleStrategy

type ScaleStrategy struct {
	kruiseV1beta1.StatefulSetScaleStrategy `json:",inline"`
	// ScaleDownStrategyType indicates the scaling down strategy.
	// Default is GeneralScaleDownStrategyType
	// +optional
	ScaleDownStrategyType ScaleDownStrategyType `json:"scaleDownStrategyType,omitempty"`
}

func (*ScaleStrategy) DeepCopy

func (in *ScaleStrategy) DeepCopy() *ScaleStrategy

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

func (*ScaleStrategy) DeepCopyInto

func (in *ScaleStrategy) DeepCopyInto(out *ScaleStrategy)

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

type ServiceQuality

type ServiceQuality struct {
	corev1.Probe  `json:",inline"`
	Name          string `json:"name"`
	ContainerName string `json:"containerName,omitempty"`
	// Whether to make GameServerSpec not change after the ServiceQualityAction is executed.
	// When Permanent is true, regardless of the detection results, ServiceQualityAction will only be executed once.
	// When Permanent is false, ServiceQualityAction can be executed again even though ServiceQualityAction has been executed.
	Permanent            bool                   `json:"permanent"`
	ServiceQualityAction []ServiceQualityAction `json:"serviceQualityAction,omitempty"`
}

func (*ServiceQuality) DeepCopy

func (in *ServiceQuality) DeepCopy() *ServiceQuality

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

func (*ServiceQuality) DeepCopyInto

func (in *ServiceQuality) DeepCopyInto(out *ServiceQuality)

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

type ServiceQualityAction

type ServiceQualityAction struct {
	State bool `json:"state"`
	// Result indicate the probe message returned by the script.
	// When Result is defined, it would exec action only when the according Result is actually returns.
	Result         string `json:"result,omitempty"`
	GameServerSpec `json:",inline"`
}

func (*ServiceQualityAction) DeepCopy

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

func (*ServiceQualityAction) DeepCopyInto

func (in *ServiceQualityAction) DeepCopyInto(out *ServiceQualityAction)

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

type ServiceQualityCondition

type ServiceQualityCondition struct {
	Name   string `json:"name"`
	Status string `json:"status,omitempty"`
	// Result indicate the probe message returned by the script
	Result                   string      `json:"result,omitempty"`
	LastProbeTime            metav1.Time `json:"lastProbeTime,omitempty"`
	LastTransitionTime       metav1.Time `json:"lastTransitionTime,omitempty"`
	LastActionTransitionTime metav1.Time `json:"lastActionTransitionTime,omitempty"`
}

func (*ServiceQualityCondition) DeepCopy

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

func (*ServiceQualityCondition) DeepCopyInto

func (in *ServiceQualityCondition) DeepCopyInto(out *ServiceQualityCondition)

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

type UpdateStrategy

type UpdateStrategy struct {
	// Type indicates the type of the StatefulSetUpdateStrategy.
	// Default is RollingUpdate.
	// +optional
	Type apps.StatefulSetUpdateStrategyType `json:"type,omitempty"`
	// RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType.
	// +optional
	RollingUpdate *RollingUpdateStatefulSetStrategy `json:"rollingUpdate,omitempty"`
}

func (*UpdateStrategy) DeepCopy

func (in *UpdateStrategy) DeepCopy() *UpdateStrategy

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

func (*UpdateStrategy) DeepCopyInto

func (in *UpdateStrategy) DeepCopyInto(out *UpdateStrategy)

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

Jump to

Keyboard shortcuts

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