v1alpha1

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

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

Index

Constants

This section is empty.

Variables

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

	// 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

This section is empty.

Types

type ValkeyCluster

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

	Spec   ValkeyClusterSpec   `json:"spec,omitempty"`
	Status ValkeyClusterStatus `json:"status,omitempty"`
}

ValkeyCluster is the Schema for the valkeyclusters API

func (*ValkeyCluster) DeepCopy

func (in *ValkeyCluster) DeepCopy() *ValkeyCluster

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

func (*ValkeyCluster) DeepCopyInto

func (in *ValkeyCluster) DeepCopyInto(out *ValkeyCluster)

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

func (*ValkeyCluster) DeepCopyObject

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

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

type ValkeyClusterList

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

ValkeyClusterList contains a list of ValkeyCluster

func (*ValkeyClusterList) DeepCopy

func (in *ValkeyClusterList) DeepCopy() *ValkeyClusterList

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

func (*ValkeyClusterList) DeepCopyInto

func (in *ValkeyClusterList) DeepCopyInto(out *ValkeyClusterList)

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

func (*ValkeyClusterList) DeepCopyObject

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

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

type ValkeyClusterNode

type ValkeyClusterNode struct {
	Pod          string   `json:"pod,omitempty"`
	IP           string   `json:"ip,omitempty"`
	ID           string   `json:"id,omitempty"`
	MasterNodeID string   `json:"master_node_id,omitempty"`
	SlotRange    string   `json:"slot_range,omitempty"`
	Flags        []string `json:"flags,omitempty"`
}

func (*ValkeyClusterNode) DeepCopy

func (in *ValkeyClusterNode) DeepCopy() *ValkeyClusterNode

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

func (*ValkeyClusterNode) DeepCopyInto

func (in *ValkeyClusterNode) DeepCopyInto(out *ValkeyClusterNode)

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

type ValkeyClusterSpec

type ValkeyClusterSpec struct {

	// +kubebuilder:validation:Minimum=1
	// Shards defines the number of shards in the valkey cluster
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	Shards int32 `json:"shards,omitempty"`

	// +kubebuilder:validation:Minimum=0
	// Replicas defines the number of replicas per shard in the cluster
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	Replicas int32 `json:"replicas,omitempty"`

	// Valkey docker image to use
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	Image string `json:"image,omitempty"`

	// Node selector
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	NodeSelector map[string]string `json:"nodeSelector,omitempty"`

	// Resources requirements and limits for the containers
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	Resources *corev1.ResourceRequirements `json:"resources,omitempty"`

	// Valkey pod storage
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	Storage *corev1.PersistentVolumeClaimSpec `json:"storage,omitempty"`

	// An optional field that specifies the minimum number of seconds for which a
	// newly created Pod should be ready without any of its containers crashing, for
	// it to be considered available.
	// This defaults to 0 (the Pod will be considered available as soon as it is ready).
	//
	// NOTE: If support for `progressDeadlineSeconds` is added in future, it must be
	// greater than `minReadySeconds` if `minReadySeconds` is specified.
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	// +kubebuilder:default=10
	MinReadySeconds int32 `json:"minReadySeconds,omitempty"`

	// Tolerations
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	Tolerations []corev1.Toleration `json:"tolerations,omitempty"`

	// Topology keys to use in StatefulSet Pod antiaffinity used to ensure that pods in a shard are run on separate hosts or separate availability zones
	// +operator-sdk:csv:customresourcedefinitions:type=spec
	AntiAffinityTopologyKeys []string `json:"antiAffinityTopologyKeys,omitempty"`
}

ValkeyClusterSpec defines the desired state of ValkeyCluster

func (*ValkeyClusterSpec) DeepCopy

func (in *ValkeyClusterSpec) DeepCopy() *ValkeyClusterSpec

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

func (*ValkeyClusterSpec) DeepCopyInto

func (in *ValkeyClusterSpec) DeepCopyInto(out *ValkeyClusterSpec)

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

type ValkeyClusterStatus

type ValkeyClusterStatus struct {

	// Conditions store the status conditions of the ValkeyCluster instances
	// +operator-sdk:csv:customresourcedefinitions:type=status
	Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`

	// Information about each pod
	// +operator-sdk:csv:customresourcedefinitions:type=status
	ClusterNodes map[string][]ValkeyClusterNode `json:"cluster_nodes,omitempty"`
}

ValkeyClusterStatus defines the observed state of ValkeyCluster

func (*ValkeyClusterStatus) DeepCopy

func (in *ValkeyClusterStatus) DeepCopy() *ValkeyClusterStatus

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

func (*ValkeyClusterStatus) DeepCopyInto

func (in *ValkeyClusterStatus) DeepCopyInto(out *ValkeyClusterStatus)

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